Friday, March 30, 2012

Remove hex from database

I have someone who altered all of the data in our database [22 million lines
]
that added in a line feed and carriage return in one of the fields. It needs
to
be removed. How do I remove hex values OD OA from a database field?Try something similar to:
declare @.crlf varchar(2)
set @.crlf = char(13) + char(10)
update mytable
set myfield = replace(myfield, @.crlf, '')
TEST ON A DEVELOPMENT DATABASE FIRST !!!!!!
Mike
"jeff fisher" <jeff@.fisher.com> wrote in message
news:OvUhzMCTFHA.2096@.TK2MSFTNGP14.phx.gbl...
> I have someone who altered all of the data in our database [22 million
lines]
> that added in a line feed and carriage return in one of the fields. It
needs to
> be removed. How do I remove hex values OD OA from a database field?

No comments:

Post a Comment