SET in procedures (take 2)

Ivan Smahin ivan_smahin at paradigmasoft.com
Fri Sep 28 08:14:51 CDT 2007


Hello Bart,

Friday, September 28, 2007, 2:49:41 PM, you wrote:

> I repost this since I pasted two times the same procedure. SORRYYYY!

> Hi List,

> please explain this:

> this sp

> create or replace procedure sp_php_setConnectionVariables(IN  
> long_userid Long)
> begin
>         set @user_id = long_userid;
> exception
>         when others THEN
>         call cm_CoreErrorHandler();
> end


> gives when called like this

> call sp_php_setConnectionVariables(15);
> select @user_id;

> null in the cursor---< unexpected result

> while this sp


> create or replace procedure sp_php_setConnectionVariables(IN  
> long_userid Long)
> begin
>         @user_id = long_userid;
> exception
>         when others THEN
>         call cm_CoreErrorHandler();
> end

> gives when called like this in VStudio

> call sp_php_setConnectionVariables(15);
> select @user_id;

15 in the cursor-->> expected result

I can not reproduce it.
Probably it is fixed already.


-- 
Best regards,
Ivan Smahin 
Senior Software Engineer
Paradigma Software, Inc
Valentina - The Ultra-Fast Database
http://www.valentina-db.com



More information about the Valentina mailing list