| Author |
Topic |
|
Swapnil
Starting Member
3 Posts |
Posted - 2006-07-26 : 03:22:28
|
| Hi all,Please help me in solving following query.Can we define in sql server the same parameter as input and output?How to do it?Thanks and regards,Swapnil.Swapnil |
|
|
chiragkhabaria
Master Smack Fu Yak Hacker
1907 Posts |
Posted - 2006-07-26 : 03:33:01
|
Yes by setting the output parameter Create proc Test (@p int out)AsSet @p =0 return @p On the above sample code @p will be acting as the input, as well as out put parameter.for details check on Book online under output parameters.Chirag |
 |
|
|
Swapnil
Starting Member
3 Posts |
Posted - 2006-07-26 : 07:49:52
|
| Thanks Chirag,following is the other method I got from someone--objectscreate proc #sp1 @x int output asset @x = @x + 1go--calculationdeclare @x intset @x = 7exec #sp1 @x outputselect @x--tidydrop proc #sp1/*results----------- 8*/Swapnil |
 |
|
|
RyanRandall
Master Smack Fu Yak Hacker
1074 Posts |
|
|
chiragkhabaria
Master Smack Fu Yak Hacker
1907 Posts |
|
|
RyanRandall
Master Smack Fu Yak Hacker
1074 Posts |
Posted - 2006-07-26 : 09:19:50
|
quote: Giving me Access denied
It's not important - there's nothing particularly exciting on that page.I guess you'd need to log in to access it Ryan Randallwww.monsoonmalabar.com London-based IT consultancy Solutions are easy. Understanding the problem, now, that's the hard part. |
 |
|
|
chiragkhabaria
Master Smack Fu Yak Hacker
1907 Posts |
Posted - 2006-07-26 : 09:47:40
|
quote: I guess you'd need to log in to access it
Aww need to create on over there then Chirag |
 |
|
|
Swapnil
Starting Member
3 Posts |
Posted - 2006-07-27 : 04:54:31
|
Sorry Ryan Randall for not mentioning your name.I am not saying that this is my code. I just did not mentioned your name that's it.Once again sorry for that and thanks for help.Regards,Swapnil.quote: Originally posted by RyanRandall
quote: following is the other method I got from someone
You could at least mention me, Swapnil http://www.sqlservercentral.com/forums/shwmessage.aspx?forumid=8&messageid=297318Ryan Randallwww.monsoonmalabar.com London-based IT consultancy Solutions are easy. Understanding the problem, now, that's the hard part.
Swapnil |
 |
|
|
RyanRandall
Master Smack Fu Yak Hacker
1074 Posts |
Posted - 2006-07-27 : 05:04:12
|
It's okay, Swapnil - I was just messin' Ryan Randallwww.monsoonmalabar.com London-based IT consultancy Solutions are easy. Understanding the problem, now, that's the hard part. |
 |
|
|
|