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 2008 Forums
 Transact-SQL (2008)
 NTEXT Datatype

Author  Topic 

Haarish
Starting Member

30 Posts

Posted - 2009-06-30 : 02:00:20
Hi All,

I have a column in my table that picks up values from a flat file in an SSIS package. Since the values for the column can be really large, I have assigned the datatype as 'ntext' but it does not extract the column value completely. I read the size of 'ntext' is 1 GB. Any ideas on why the text is getting truncated?

Regards,
Haarish.

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2009-06-30 : 02:29:14
NTEXT is deprecated. Use NVARCHAR(MAX) instead.

Is your file UNICODE? If not, there is no need to use NVARHAR(MAX); You can use VARCHAR(MAX) instead (2GB text).



N 56°04'39.26"
E 12°55'05.63"
Go to Top of Page

Haarish
Starting Member

30 Posts

Posted - 2009-06-30 : 02:32:31
Thanks Peso. I will use nvarchar(max).
Go to Top of Page

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2009-06-30 : 03:10:44
And if you are doing your control select it is possible that your query window is truncating the output result even though the data is in the table.
You can configure this in options of ssms.


No, you're never too old to Yak'n'Roll if you're too young to die.
Go to Top of Page
   

- Advertisement -