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)
 DTS Export to Text File Truncates Column to 255

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-07-26 : 16:32:01
Joe writes "I am having DTS problem exporting from a table to a text file (my 600 character table column is truncated to 255 characters in the output text file). I don't why this is happining nor how to get the DTS not truncate to 255 characters. Is this a bug? A limitation? How do I get around this problem?
.......I am running SQL Server 7 SP1 and database is in 6.5 compatability mode."

dr fonz
Starting Member

6 Posts

Posted - 2002-07-05 : 09:29:51
I've had this problem too, on more than one SQL server setup (none in compatibility mode). The same happens if you export to a XL spreadsheet. I can only guess MS forgot that they extended the varchar beyond 255 when they wrote the DTS stuff?!

Anyway. The only way I found to get round it was to export with a query, not a table, and convert the long varchar to a text field in the export; eg:

SELECT ID, CONVERT(text, BigVarcharField) AS BigVarcharField FROM MyTable

Throw the query into a SP to save effort etc. if you like.

It's a bit laborious if you're just trying to whack off a quick export, but it works if you're desperate!

Guess it's best to steer clear of text files, they are a very dated medium after all ;)

Or you could use BCP or whatever

Go to Top of Page
   

- Advertisement -