I have a real mystery here. I have a stored procedure that works when I call it from SQL Server Query Analyzer, but returns EOF when I call it from my VB code. I even took the code that makes up the stored procedure and try running that from VB with the same results.
Here's the SQL code I'm using:
select * from GetProcessedTimecards where Header_ID in (select distinct Header_ID from GetEditedProcessedRecords where WeekEnding < '1/3/2003' and EditDate between '1/3/2003' and '1/10/2003')
I'm running the SQL code from within my VB app by using a persistent connection to my database. Here's what my VB code looks like:
Set rc = New ADODB.Recordset
With rc
.ActiveConnection = cnOnlineTimecard
.CursorLocation = adUseServer
.Source = SSQL
.Open
End With
Any idea why this would work in SQL Query Analyzer but not in VB would be greatly appreciate it.
Here's the SQL code I'm using:
select * from GetProcessedTimecards where Header_ID in (select distinct Header_ID from GetEditedProcessedRecords where WeekEnding < '1/3/2003' and EditDate between '1/3/2003' and '1/10/2003')
I'm running the SQL code from within my VB app by using a persistent connection to my database. Here's what my VB code looks like:
Set rc = New ADODB.Recordset
With rc
.ActiveConnection = cnOnlineTimecard
.CursorLocation = adUseServer
.Source = SSQL
.Open
End With
Any idea why this would work in SQL Query Analyzer but not in VB would be greatly appreciate it.