Page 1 of 1

Execute Store Procedure that contain select statement

Posted: Thu 17 Feb 2011 06:26
by overvi
I am using UNIDAC latest version on MS SQL Server 2005.
I have a query statement :

CREATE TABLE #customer
( CusId varchar(25),
CusName varchar(50),
CusAddress varchar(100) )
exec S_InsertandSelectCustomer


the store proc S_InsertandSelectCustomer contain insert statement to table #customer and then select it.
If i run the sql stement using UniQuery. and error message
table #customer not found.
What should i do ?
Our old program using BDE can run this with no problem.

Posted: Thu 17 Feb 2011 13:27
by AndreyZ
Hello,

I cannot reproduce the problem. Please try composing a small sample to demonstrate the problem and send it to andreyz*devart*com, including a script to create the S_InsertandSelectCustomer stored procedure.

Posted: Wed 23 Feb 2011 08:23
by overvi
I already found it what's wrong with my code. I am using prepare before open the query. This make the table is not recognized.

Posted: Wed 23 Feb 2011 10:55
by AndreyZ
It is good to see that this problem was solved. If any other questions come up, please contact us.

Posted: Wed 23 Feb 2011 13:30
by overvi
Hello AndreyZ

Thanks for you help.