Row count in Oracle #247
-
Good afternoon, For example if I run simple test and select e.g. 400 records. I'm trying to confirm in the network packet, that there were 400 records received back. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 5 replies
-
this is the beginning of the response:
and this is the end of the response:
|
Beta Was this translation helpful? Give feedback.
-
Yes, the value is found in the error record (found at the end of the response). It is the third field (starting at byte 0x95c and consisting of the bytes 0x02, 0x01, 0x90) and indicates the value is 400. Since that field can only go up to 4 bytes (2 ^ 32) the value is also found near the end of the record (starting at byte 0x97e and also consisting of the bytes 0x02, 0x01, 0x90) and indicates the value is 400. This value can go up to 8 bytes (2 ^ 64). The Python driver only pays attention to the second value (for DML) and ignores it for queries -- since by that point the driver has already processed all of the rows and doesn't need to be told how many are there! |
Beta Was this translation helpful? Give feedback.
Yes, the value is found in the error record (found at the end of the response). It is the third field (starting at byte 0x95c and consisting of the bytes 0x02, 0x01, 0x90) and indicates the value is 400. Since that field can only go up to 4 bytes (2 ^ 32) the value is also found near the end of the record (starting at byte 0x97e and also consisting of the bytes 0x02, 0x01, 0x90) and indicates the value is 400. This value can go up to 8 bytes (2 ^ 64).
The Python driver only pays attention to the second value (for DML) and ignores it for queries -- since by that point the driver has already processed all of the rows and doesn't need to be told how many are there!