Discussion:
Creating a formated txt file from query
(too old to reply)
Ana
2007-11-28 23:26:42 UTC
Permalink
Hi,



I need to export a query into a file with a delimiter text so it can be
imported by an application The format should be something like: 1st column =
10 characters, 2nd column= 4 characters and so on. Reason being is that the
application can read and import the text.

How should I go by?

TIA

Ana
Tom Moreau
2007-11-29 00:08:56 UTC
Permalink
There's a difference between delimited and fixed-width columns. What you
have described if fixed-width. The column widths can be specified in a
format file, used in conjunction with the BCP.EXE utility.

http://msdn2.microsoft.com/en-us/library/ms191516.aspx
--
Tom

----------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA, MCITP, MCTS
SQL Server MVP
Toronto, ON Canada
https://mvp.support.microsoft.com/profile/Tom.Moreau


"Ana" <***@yahoo.es> wrote in message news:8D72F2DC-E4B2-43B2-8C73-***@microsoft.com...
Hi,



I need to export a query into a file with a delimiter text so it can be
imported by an application The format should be something like: 1st column =
10 characters, 2nd column= 4 characters and so on. Reason being is that the
application can read and import the text.

How should I go by?

TIA

Ana
Loading...