question

SQL-erform avatar image
SQL-erform asked

Update instruction

Hi, I'd like to rename about 200 articlenumbers with an update instruction. All these articelnumbers have 18 digits and contain at digit 15+16 two capitals for example 140Vx281018000MI11. The capitals MI in these articlenumbers have to be replaced into WD. Does anyone have the right update instruction for me? Thanks in advance. SQL-erform

update
10 |1200 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
Squirrel 1 avatar image
Squirrel 1 answered
update t            
set    articelnumbers = replace(articelnumbers , 'MI', 'WD')            
from   yourtable t            
where  articelnumbers like '%MI%'            
10 |1200 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.