PostgreSQL

PgSQL: Replace Add break

UPDATE m_product

SET em_mg_longdescription = regexp_replace(em_mg_longdescription,’————‘,chr(13))

WHERE
em_mg_manufacturer = 1000637
AND value = ‘IMI-YW356A01′

 

 

Some additional replace scripts

 

UPDATE m_product

SET em_mg_longdescription = regexp_replace(em_mg_longdescription,'</li>’,chr(10))

WHERE
em_mg_manufacturer = 1000637

 

UPDATE m_product

SET em_mg_longdescription = replace(em_mg_longdescription,'<li>’,”)

WHERE
em_mg_manufacturer = 1000637

 

UPDATE m_product

SET em_mg_longdescription = replace(em_mg_longdescription,'<ul>’,”)

WHERE
em_mg_manufacturer = 1000637

 

UPDATE m_product

SET em_mg_longdescription = replace(em_mg_longdescription,'</ul>’,”)

WHERE
em_mg_manufacturer = 1000637

Leave a Reply

Your email address will not be published. Required fields are marked *