| Author |
Topic |
|
haroon2k9
Constraint Violating Yak Guru
328 Posts |
Posted - 2010-02-17 : 09:19:36
|
| Hi,pl see below Data<example1><exam>ple2examp<le3>ex<am>ple4above to be Replaced like<example1><exam>ple2examp<le3>ex<am>ple4Needs to replace< to <> to >which exists anywhere in the string,has to be replaced to corresponding format.. |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2010-02-17 : 09:22:51
|
| what? its showing both as same thing.------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2010-02-17 : 09:26:33
|
[code]replace(replace(col, '<', '<'), '>', '>')[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2010-02-17 : 09:57:08
|
quote: Originally posted by haroon2k9 Hi,pl see below Data<example1><exam>ple2examp<le3>ex<am>ple4above to be Replaced like<example1><exam>ple2examp<le3>ex<am>ple4Needs to replace< to <> to >which exists anywhere in the string,has to be replaced to corresponding format..
You leave the data as such. There is no need of updationMadhivananFailing to plan is Planning to fail |
 |
|
|
haroon2k9
Constraint Violating Yak Guru
328 Posts |
Posted - 2010-02-17 : 10:05:34
|
| iam sorry this seems to be happened like html decode. :)pl see below< is ampersandlt> is ampersandgtnow please help me to replace it. |
 |
|
|
haroon2k9
Constraint Violating Yak Guru
328 Posts |
Posted - 2010-02-17 : 10:11:27
|
| like,here html decode be used inbuilt way.so i couldn't show you the actual data.so let me add this way below ok.in place of & ,let me put this as a ampersand ok.replace in my string asampersandlt is to be replaced as <(less than symbol)ampersandgt is to replaced as >(Greater than symbol) |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2010-02-17 : 10:25:19
|
| didnt this work?replace(replace(col, 'ampersandlt', '<'), 'ampersandgt', '>')again make sure you replace ampersandgt with symbol------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
haroon2k9
Constraint Violating Yak Guru
328 Posts |
Posted - 2010-02-17 : 12:05:23
|
quote: Originally posted by visakh16 didnt this work?replace(replace(col, 'ampersandlt', '<'), 'ampersandgt', '>')again make sure you replace ampersandgt with symbol------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/Thank you vishak.worked..Thanks for every one
|
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2010-02-17 : 12:08:34
|
welcome ------------------------------------------------------------------------------------------------------SQL Server MVPhttp://visakhm.blogspot.com/ |
 |
|
|
|