Link to home
Start Free TrialLog in
Avatar of dthobart
dthobart

asked on

Using Replace command in TEXT datatype column.

I am trying to replace a preset charcter string with 'formfeed+linefeed' in a TEXT field.  This ata was loaded via SQL and lost it's formatting, so I have decided to try to reinsert the carriage returns by replacing a character string that will be inserted into the SQL in place of the carriage returns.

select replace(ldtext, '9988899', char(13)+char(10)) from longdescription where ldkey in (select ldkey from equipment where eqnum = 'EC-BFP-004')

Error: Microsoft SQL Server:8116[Microsoft][ODBC SQL Server Driver][SQL Server]Argument data type text is invalid for argument 1 of replace function.Microsoft SQL Server:8180[Microsoft][ODBC SQL Serv

Any ideas?

Thanks.
ASKER CERTIFIED SOLUTION
Avatar of Lori99
Lori99

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial