Subject | Problem in Firebird Recordset ADO 2.5 |
---|---|
Author | Others |
Post date | 2010-05-08T02:57:46Z |
Good morning,
I have problem with my VB6 recordset ADO 2.5. I am using Firebird 2.1.
My data are:
DATA_1
DATA_2
DATA_3
DATA_4
DATA_5
I open my recordset as follow:
rs.open "SELECT * FROM myData", conn, adOpenDynamic, adLockOptimistic
Now I want to know HOW MUCH records are available:
rc = 0
While Not rs.EOF
rc = rc + 1
rs.MoveNext
Wend
This function returns correct value: 5 records....
Now, I want to display those record:
rs.MoveFirst
While Not rs.EOF
MsgBox rs.Fields(0).Value
rs.MoveNext
Wend
Weird enough, that function only display record: DATA_2 up to DATA_5, where
DATA_1 was skipped !!!
But if I set cursor location to adUseClient, DATA_1 can be displayed.
Now, my problem is: Why rs.MoveFirst did not move the recordset to the first
record?
Any suggestions?
Regards,
Yasa Yap.
[Non-text portions of this message have been removed]
I have problem with my VB6 recordset ADO 2.5. I am using Firebird 2.1.
My data are:
DATA_1
DATA_2
DATA_3
DATA_4
DATA_5
I open my recordset as follow:
rs.open "SELECT * FROM myData", conn, adOpenDynamic, adLockOptimistic
Now I want to know HOW MUCH records are available:
rc = 0
While Not rs.EOF
rc = rc + 1
rs.MoveNext
Wend
This function returns correct value: 5 records....
Now, I want to display those record:
rs.MoveFirst
While Not rs.EOF
MsgBox rs.Fields(0).Value
rs.MoveNext
Wend
Weird enough, that function only display record: DATA_2 up to DATA_5, where
DATA_1 was skipped !!!
But if I set cursor location to adUseClient, DATA_1 can be displayed.
Now, my problem is: Why rs.MoveFirst did not move the recordset to the first
record?
Any suggestions?
Regards,
Yasa Yap.
[Non-text portions of this message have been removed]