Seemingly simple problem....
I'm looping through ADO's recordset as follows:
Code:
ADODB::_RecordSetPtr recordSet;
recordSet = m_pDB->OpenStoredProcedure(&strSPName, usualparams...);
while (!recordSet->EndOfFile)
{
int nValue = recordSet->Fields->GetItem("FieldName")->GetValue().iVal;
recordSet->MoveNext();
}
The above code, logically speaking, works and has no errors - I get the output that I expect for records that are in the DB.
However, when I run the stored proc thats being passed into the OpenStoredProcedure method in say Query Analyser, I get around 23500 records.
If I run the above code in VC++, I get far less records returned...about 10%!!
WHY??
Regards