December 16, 2009 at 3:10 pm
Hi I am trying to Update a text column in a table and Normal update is not working, so can some one help me out in writing an update statement,
CREATE TABLE [dbo].[frWorkflow](
[WorkFlowID] [uniqueidentifier] NOT NULL,
[WorkflowDefinition] [text] NOT NULL,
[IsDeleted] [char](1) NOT NULL,
[RecordingUserName] [varchar](25) NOT NULL,
[RecordingTime] [datetime] NOT NULL,
[RowVersion] [int] NOT NULL,
CONSTRAINT [PK_frWorkflow] PRIMARY KEY CLUSTERED
(
[WorkFlowID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
update frWorkflow set WorkFlowDefinition = '<Workflow> <Definition><ns0:ShashiFailureWorkflow x:Name="TestFailureWorkflow" HasErrors="False" JobParameterString="Nothing" Exception="{x:Null}" xmlns:ns1="clr-namespace:FileOneFramework.JobManager.WorkflowActivities;Assembly=FileOneFramework.JobManager.WorkflowActivities" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:ns0="clr-namespace:FileOneFramework.JobManager.Workflows;Assembly=FileOneFramework.JobManager.Workflows"> <ns1:TestFailureActivity x:Name="testFailureActivity1" Description="This is a test activity that will throw an error." /> </ns0:TestFailureWorkflow></Definition> <Rules /> </Workflow>'
where WorkFlowID = 'FB9C894D-5476-401D-BE95-086AF4528E52' and rowversion = 26
December 16, 2009 at 3:47 pm
Opps I found the mistake...
December 16, 2009 at 4:57 pm
Cool! Tell us what it was please?
Also, if you're using SQL Server 2005 (this is a 2005 forum), why don't you convert the TEXT column to a VARCHAR(MAX) column and call it a day?
--Jeff Moden
Change is inevitable... Change for the better is not.
December 16, 2009 at 5:45 pm
Most excellent suggestion Jeff. The update will need to happen at some point anyway with Text going away in a future release.
Jason...AKA CirqueDeSQLeil
_______________________________________________
I have given a name to my pain...MCM SQL Server, MVP
SQL RNNR
Posting Performance Based Questions - Gail Shaw[/url]
Learn Extended Events
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply