Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
DB Engine
SQL ServerMSDESQL Server CE
Services
Analysis (Data Mining)Analysis (OLAP)DTSIntegration ServicesNotification ServicesReporting Services
Programming
CLRConnectivitySQLXML
Other Technologies
ClusteringEnglish QueryFull-Text SearchReplicationService Broker
General
Data WarehousingPerformanceSecuritySetupSQL Server ToolsOther SQL Server Topics
DirectoryUser Groups
Related Topics
MS AccessOther DB ProductsMS Server Products.NET DevelopmentVB DevelopmentJava DevelopmentMore Topics ...

SQL Server Forum / Other Technologies / Full-Text Search / July 2007

Tip: Looking for answers? Try searching our database.

Help adding text to column with sql 2005 query

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
astra14i@hotmail.com - 30 Jul 2007 23:25 GMT
Hi there,
I'm quit newby to this, so i'd like to have some help please.

I've a column whit some text where i want to insert more text before
and after, with sql 2005.
I'm trying this way, without success:

....
update dbo.log
SET dbo.log.text = ('lot1' + dbo.log.text + 'lot2')

What shall i do in order to have success?
Thanks in advance.
Daniel Crichton - 31 Jul 2007 08:22 GMT
astra14i@hotmail.com wrote  on Mon, 30 Jul 2007 15:25:38 -0700:

> Hi there,
> I'm quit newby to this, so i'd like to have some help please.
[quoted text clipped - 9 lines]
> What shall i do in order to have success?
> Thanks in advance.

Maybe it's because text is a reserved keyword, as is log. Try this:

UPDATE dbo.[log]
SET [text] = 'lot1' + [text] + 'lot2'

If it gives the same result then how about posting some DDL. If [text] is a
text column, try changing it to a varchar(max) - a text column will probably
need to use the UPDATETEXT statement, but it's been a long time since I've
used it.

Dan
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.