csv - mysql replace unwanted symbols and characters -


i have huge mysql database table. table (here showing 5 rows)

id categories 1  !98!n!85!n!73!n!76!n 2  !110!n!29!n!76!n!75!n!81!n!80!n!37!n!42!n!1!n!150! 3  !73!n!80!n!81!n!75!n!76!n!110!n!29!n!37!n!42!n!1!n!127!n!30!n!84!n!6!n!150!n!126!n 4  !24!n!147!n!73!n 5  !59!n!97!n!73!n 

here can see in categories have data !98!n!85!n!73!n!76!n. here can see there ! symbol before , after number , , there n after numbers. want remove unwanted datas , use comma in between 2 numbers. data this

98,85,73,76 

so can tell me how in smarter way. , suggestions helpful.

execute

update mytable set stringcolumn = replace(stringcolumn, '!n!',','); 

after execute

update mytable set stringcolumn = replace(stringcolumn, '!n',''); 

after execute

update mytable set stringcolumn = replace(stringcolumn, '!',''); 

may you


Comments

Popular posts from this blog

angularjs - ADAL JS Angular- WebAPI add a new role claim to the token -

php - CakePHP HttpSockets send array of paramms -

node.js - Using Node without global install -