Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 221
  • Last Modified:

RecordCount = -1 (???)

Something "strange" in D5 and Oracle7.3.4. The application runs a SELECT statement in a table which contains VARCHAR2(2000) fields. Well... sometimes (only SOMETIMES) I get a RecordCount with value = -1 (negative 1). Any idea?
0
binho
Asked:
binho
  • 3
1 Solution
 
binhoAuthor Commented:
Motaz: sure it is opened. That's when it returns -1.
0
 
EpsylonCommented:
Here is a link that relates to this:

http://www.borland.com/devsupport/sqllinks/pub-52.html


Another thing you could try is to call 'FetchAll' before you read 'RecordCount'. However this could be slow...

Regards,

Epsylon.
0
 
MotazCommented:
Make sure that the DataSet is opened
0
 
binhoAuthor Commented:
I just found out that it returns -1 only when the number of rows returned is greater than 10. If the # is eleven, then I get -1.
0
 
binhoAuthor Commented:
Calling FetchAll before reading RecordCount solve the problem :))
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now