views:

210

answers:

1

How can you get the number of affected rows from executing a "MERGE INTO..." sql command within CX_Oracle?
When ever I execute the MERGE SQL on cx_oracle, I get a cursor.rowcount of -1. Is there a way to get the number of rows affected by the merge?

+1  A: 

Since cx_oracle follows the python DBAPI specification (I presume), this is expected 'behaviour'. The exact same problem was discussed here on stackoverflow before.

Some more links with possible solutions:

ChristopheD