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.
| Author |
Topic |
|
Nesu
Starting Member
15 Posts |
Posted - 2007-03-19 : 12:21:04
|
| Hi, I'm new to SQL sever and am using SQL Server Management Studio Express 2005.I've written my query that returns too many rows to be looked at Excel, and so wish to view and perform my calculations in SAS.However, I don't know how to export the data I am getting in to SAS. I have tried using the Results to File option, but when I try import this into SAS it doesn't like the data.Is there some option I need or is there anyway I can export the data to SAS.Thanks a lot.Nesu. |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2007-03-19 : 13:38:15
|
| This looks like a SAS problem rather than sql server.Another option is to export to a csv file and then import to access.What do you want to do with the data?==========================================Cursors are useful if you don't know sql.DTS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
|
Nesu
Starting Member
15 Posts |
Posted - 2007-03-20 : 05:48:42
|
| It would probably work if I could export it as CSV file as I know that SAS can read them. Whats the best way to do this? I've tried changing the extension of the Results to File option, but I guess this isn't the correct way.As for what I'm trying to do, I'm looking at a results set that is far larger than what Excel can handle, and as we already use SAS at work and have it installed, it makes sense for us to manipulate the data in there.Thanks.Nesu. |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-03-20 : 06:29:15
|
| Excel now can handle 1 million rows/records.Peter LarssonHelsingborg, Sweden |
 |
|
|
Nesu
Starting Member
15 Posts |
Posted - 2007-03-20 : 06:41:29
|
| Thanks, for that. However, I still working with an older version of Excel which can't handle that many rows hence the need to use in SAS. The company won't be upgrading for a while yet and we need to be able to access this data to get it out to customers. |
 |
|
|
nr
SQLTeam MVY
12543 Posts |
Posted - 2007-03-20 : 08:06:29
|
| bcp or ssis can export to a csv file.Management studion can also output the resultset to a file - don't know about express though.==========================================Cursors are useful if you don't know sql.DTS can be used in a similar way.Beer is not cold and it isn't fizzy. |
 |
|
|
readysetstop
Posting Yak Master
123 Posts |
Posted - 2007-03-20 : 08:24:03
|
| Save your query to a file (query.txt, if you like) and use bcp.exe to get the data out in CSV format. |
 |
|
|
|
|
|
|
|