Link to home
Start Free TrialLog in
Avatar of caracalla
caracalla

asked on

Stored procedure won't return to VB

VB 6.0; SQL Server 2000

A stored procedure runs perfectly well from SQL Query Analyzer. However, from VB, it won't return anything. If I comment the SQL totally from stored procedure and replace it with 'hello', it returns 'hello' to VB. The parameters are OK.
Avatar of flavo
flavo
Flag of Australia image

Can we see some code?  VB and T-SQL would be handy

Dave
Avatar of Guy Hengel [angelIII / a3]
I assume all you need to do is to add the following line to the procedure:

CREATE PROCEDURE yourproc
AS
SET NOCOUNT ON       --- add this line
... here comes the rest of your proc code
Avatar of caracalla
caracalla

ASKER

found it: SET NOCOUNT ON


There were 2 sets of select statements.
ASKER CERTIFIED SOLUTION
Avatar of Guy Hengel [angelIII / a3]
Guy Hengel [angelIII / a3]
Flag of Luxembourg image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial