Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Merge in Text files
Message
 
 
To
13/04/2010 08:39:41
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Environment versions
SQL Server:
SQL Server 2000
Application:
Desktop
Miscellaneous
Thread ID:
01459909
Message ID:
01459912
Views:
38
Yes, you can use
declare @Result varchar(8000)

set @Result = ''

select @Result = @Result + coalesce(Field1,'') from myTable
select @Result -- assuming that there are not that many records to fit to 8000 characters limit.
For BCP approach you may want to take a look at this blog
http://blogs.lessthandot.com/index.php/DataMgmt/DataDesign/how-to-script-all-stored-procedures-in-a

>Hi All,
>
> i Have a table with a single field in SQL2000 and i want it to save into text file in continues format.
>Ex.
>Table1
>Field1
>rec1
>rec2
>rec3
>rec4
>rec5
>...
>
>is't possible to copy all the records in table1 to text file(Text1.txt) and the text file should look like this
>
>rec1rec2rec3rec4rec5...
>
>Thanks.
>ryan
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform