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
 Old Forums
 CLOSED - General SQL Server
 SQL Question

Author  Topic 

seabaz2000
Starting Member

3 Posts

Posted - 2006-03-05 : 09:01:15
hi
I was just wondering if its possible to store more than one field of data in a variable. For example suppose you have a table as follows:
Table1
name password Username
John komodo johno
Jay cazouys jayzy
peep sooky seaba


If i declare a variable @x and try to store all the passwords in that variable, all that happens is I get one item in the variable.
ie


SELECT @x = password FROM Table1.....

Is there anyway around this, i.e. can u use arrays etc..
Regards

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2006-03-05 : 09:10:52
CSV ? see here http://sqljunkies.com/WebLog/amachanic/archive/2004/11/10/5065.aspx

----------------------------------
'KH'


Go to Top of Page
   

- Advertisement -