Unix Technical Forum

DEFINITIVE ANSWER PLEASE -- can you UPDATE ntext datatype field???

This is a discussion on DEFINITIVE ANSWER PLEASE -- can you UPDATE ntext datatype field??? within the SQL Server forums, part of the Microsoft SQL Server category; --> Hi, I've read conflicting articles on updating an ntext field in a column. My ntext field will exceed 8,000 ...


Go Back   Unix Technical Forum > Database Server Software > Microsoft SQL Server > SQL Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-28-2008, 07:11 PM
KathyB
 
Posts: n/a
Default DEFINITIVE ANSWER PLEASE -- can you UPDATE ntext datatype field???

Hi, I've read conflicting articles on updating an ntext field in a
column.

My ntext field will exceed 8,000 characters (typically twice that size
-- but just a text string).

One article (I think from MicroSoft) said you could NOT use ntext in
an UPDATE statement, but I've seen examples from other people using
it...but don't know if it's related to the size/characters issue.

Is this true or not?

Thanks very much...Kathy
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-28-2008, 07:11 PM
Erland Sommarskog
 
Posts: n/a
Default Re: DEFINITIVE ANSWER PLEASE -- can you UPDATE ntext datatype field???

KathyB (KathyBurke40@attbi.com) writes:
> One article (I think from MicroSoft) said you could NOT use ntext in
> an UPDATE statement, but I've seen examples from other people using
> it...but don't know if it's related to the size/characters issue.


Yes, you can update an ntext column directly in an UPDATE statement.
I dont think there is a limitation, but it may be unpractiable if
you have a string which is million characters long.

There is also UPDATETEXT which permits you change parts of an ntext
column, but this function is certainly more complex to use, so as long
as you can do it with plain UPDATE stay with it.


--
Erland Sommarskog, SQL Server MVP, sommar@algonet.se

Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-28-2008, 07:11 PM
Kathy Burke
 
Posts: n/a
Default Re: DEFINITIVE ANSWER PLEASE -- can you UPDATE ntext datatype field???

Thanks, Erland, that's what I wanted to hear!

I don't need to save a million, just up to 50,000!

Kathy

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:12 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com