dbTalk Databases Forums  

HELP: FUNCTION and PROCEDURE best practices....

comp.databases.mysql comp.databases.mysql


Discuss HELP: FUNCTION and PROCEDURE best practices.... in the comp.databases.mysql forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
daniel@mfaconsulting.com
 
Posts: n/a

Default HELP: FUNCTION and PROCEDURE best practices.... - 09-26-2006 , 06:26 AM






Its not a question of marking them as IN or OUT or INOUT....

CREATE PROCEDURE `sp_test01`(IN _var1 INT, IN _var2 INT, OUT _Ret INT)
BEGIN

START TRANSACTION;

-- Do some insert

COMMIT;

SET _Ret = 1;

END$$

....its that in C#

I have to call this with variables called _var1,_var2 and _Ret.....if
you get that wrong it doesn't work. Specifically WRT getting the _Ret
variable!

Anyway, thanks for the reply.

D.


Reply With Quote
  #2  
Old   
Jerry Stuckle
 
Posts: n/a

Default Re: HELP: FUNCTION and PROCEDURE best practices.... - 09-26-2006 , 07:54 AM






daniel (AT) mfaconsulting (DOT) com wrote:
Quote:
Its not a question of marking them as IN or OUT or INOUT....

CREATE PROCEDURE `sp_test01`(IN _var1 INT, IN _var2 INT, OUT _Ret INT)
BEGIN

START TRANSACTION;

-- Do some insert

COMMIT;

SET _Ret = 1;

END$$

...its that in C#

I have to call this with variables called _var1,_var2 and _Ret.....if
you get that wrong it doesn't work. Specifically WRT getting the _Ret
variable!

Anyway, thanks for the reply.

D.

Yep, that's true. That's the way SP's work.

But the same is true with C# functions, is it not? If you don't call
them with the correct parameters it doesn't work?

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex (AT) attglobal (DOT) net
==================


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.