You are here: Re: ISQL is truncating contents of text field sent to text file. « MsSQL Server « IT news, forums, messages
Re: ISQL is truncating contents of text field sent to text file.

Posted by Rod on 07/10/07 16:36

On 9 jul, 16:39, Erland Sommarskog <esq...@sommarskog.se> wrote:
> Rod (rod.pe...@gmail.com) writes:
> > BCP seems the way to go as it's not truncating the output and writes
> > without a prob upto 100k chars per line (tested). Now, something that
> > surfaced after some testing to implement BCP usage, is that BCP only
> > writes to text file the very first "select" statement of the several
> > that conform my stored procedure, will need to find a workaround.
>
> In your original post you only talk about a table with the data type
> text. Suddently there are stored procedures. Do these procedures use
> FOR XML? Or do they select from text column that just happens to hold
> XML.
>

The text data is being generated on-the-fly using FOR XML by running
several Select statements in series (some headers and elements are
also sent to output). All these was compiled into a Stored Procedure
for modularity.

At first we were inserting each FOR XML to a table (SQL2k5)
only to find the solution won't run under SQL 2000, so we rolled back
to find a single solution compatible with SQL Server 2k & 2k5.

After asking on usenet, and being suggested to use BCP, we now
get a text-file including the output (w/o truncation) from the very
first Select statement inside the SP while the other Select statements
are ignored or not included in the text-file generated by BCP.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация