Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

I want to Replace a special charact

Status
Not open for further replies.

db2sachin

Programmer
Jun 9, 2003
24
AU
I want to Replace a special character with some other character using Replace function. The character to be replaced is '. Now how do i do it ?
I tried this...
update TTM_AIR_TICKET_MST set ATC_AIR_TKT_STATUS_CD = replace(ATC_AIR_TKT_STATUS_CD,'/''{escape '/'},'O' ) ;
 
update TTM_AIR_TICKET_MST set ATC_AIR_TKT_STATUS_CD = replace(ATC_AIR_TKT_STATUS_CD,'''','O' ) ;
 
That means single quotes (') itself is an escape character for db2 ?
 
Effectively. Two single quotes together are interpreted as one single quote.
 
How to escape semicolon character in a select statement?

eg: select ';' from sometable

I get a execption while trying to execute the above statement.

Someone plz me with this.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top