4

I just ran a rather simple INSERT statement (that I think processed a lot of rows), and I got the message:

-1,311,750,183 rows inserted

Should I be concerned about the fact that it's negative?

5
  • 1
    Which DBMS are you using? Commented Jul 11, 2013 at 21:02
  • 1
    I smell 32-bit DB software. Commented Jul 11, 2013 at 21:10
  • SQL Developer. How can I check if I'm using 32 or 64 bit? Commented Jul 12, 2013 at 10:58
  • SELECT * FROM V$VERSION
    – msi77
    Commented Jul 12, 2013 at 16:06
  • Nope, it's 64 bit: Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production PL/SQL Release 11.2.0.2.0 - Production "CORE 11.2.0.2.0 Production" TNS for Linux: Version 11.2.0.2.0 - Production NLSRTL Version 11.2.0.2.0 - Production Commented Jul 14, 2013 at 11:43

1 Answer 1

5

It is possible that the number of rows exceed the value of PLS_INTEGER. Here is the quote from Oracle on %ROWCOUNT.

%ROWCOUNT Attribute: How Many Rows Were Fetched? %ROWCOUNT returns: Zero after the explicit cursor is opened but before the first fetch Otherwise, the number of rows fetched (a PLS_INTEGER) Note: If the number of rows exceeds the maximum value for a PLS_INTEGER, then SQL%ROWCOUNT returns a negative value. For information about PLS_INTEGER, see "PLS_INTEGER and BINARY_INTEGER Data Types".

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.