MacMorag
Sun 9th Jan '05, 9:24pm
Hi guys,
I am trying to do the following (but having no luck). Does anyone know the query to do this:
I have one column where every record is in the format "abcd/123xxx456"
I want to replace the record so that it looks like "abcd/xxx/123xxx456"
xxx is different for every record
Why does this not work?
UPDATE columnA SET fieldB = REPLACE(fieldB, 'abcd/123*456'', 'abcd/*/123*456');
I'm guessing that you can't use the wildcard to extract and hold the value of xxx for each record. Is there another way to do this?
Any assistance is much appreciated.
Thanks :)
I am trying to do the following (but having no luck). Does anyone know the query to do this:
I have one column where every record is in the format "abcd/123xxx456"
I want to replace the record so that it looks like "abcd/xxx/123xxx456"
xxx is different for every record
Why does this not work?
UPDATE columnA SET fieldB = REPLACE(fieldB, 'abcd/123*456'', 'abcd/*/123*456');
I'm guessing that you can't use the wildcard to extract and hold the value of xxx for each record. Is there another way to do this?
Any assistance is much appreciated.
Thanks :)