Skip to content

Oracle.EntityFrameworkCore update statement and checking rows affected #180

Open
@SierraNL

Description

@SierraNL

When creating an update the following SQL is generated:

DECLARE
v_RowCount INTEGER;
BEGIN
UPDATE "MyTable" SET "Processed" = :p0, "Updated" = :p1
WHERE "Id" = :p2 AND "Type" = :p3 AND "MessageId" = :p4;
v_RowCount := SQL%ROWCOUNT;
OPEN :cur1 FOR SELECT v_RowCount FROM DUAL;
 
END;

This code is not efficient because it requires context switching and setting up a new cursor.

is there no other way within the framework that can process the return value of the UPDATE statement?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions