Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 How do get output

Author  Topic 

TAS
Yak Posting Veteran

65 Posts

Posted - 2004-04-15 : 11:12:58
Select decPaid,vchrType, sdtmDate from tblFee Where vchrNumEnroll=@Enroll

My question is: How to output decPaid,vchrType and sdtmDate into different variable? I need to use these output values in program.

Aiby
Yak Posting Veteran

71 Posts

Posted - 2004-04-15 : 11:46:05
can you explain it little more clearly?! this part >> "into different variable" what do you exacly meaned!
Go to Top of Page

TAS
Yak Posting Veteran

65 Posts

Posted - 2004-04-15 : 11:52:36
I want to get return value from decPaid,vchrType, sdtmDate.
Go to Top of Page

Amethystium
Aged Yak Warrior

701 Posts

Posted - 2004-04-15 : 11:57:46
[code]

declare @decPaid money
declare @vchrType varchar(50)
declare @sdtmDate datetime

Select
@decPaid = decPaid,
@vchrType = vchrType
@sdtmDate = sdtmDate
from
tblFee
Where vchrNumEnroll=@Enroll
[/code]

but you have to make sure that only single values are inserted in to the variables.



select

________________
Make love not war!
Go to Top of Page

TAS
Yak Posting Veteran

65 Posts

Posted - 2004-04-15 : 12:14:38
Amethystium:

It works fine.Thanks!
Go to Top of Page
   

- Advertisement -