Re: Editing fields in bulk

2007-09-05 Thread Martijn Tonies
> I have a column where I need to replace all instances of the text "US- > Complete" (contained within a long sentence) with "US Complete". > There are probably 50 or 100 of them. I'm really scared to do it > since I can't risk screwing up that column - what's the correct syntax? When you s

Re: Editing fields in bulk

2007-09-04 Thread Baron Schwartz
Brian Dunning wrote: I have a column where I need to replace all instances of the text "US-Complete" (contained within a long sentence) with "US Complete". There are probably 50 or 100 of them. I'm really scared to do it since I can't risk screwing up that column - what's the correct syntax?

Re: Editing fields in bulk

2007-09-04 Thread Gary Josack
Brian Dunning wrote: I have a column where I need to replace all instances of the text "US-Complete" (contained within a long sentence) with "US Complete". There are probably 50 or 100 of them. I'm really scared to do it since I can't risk screwing up that column - what's the correct syntax?

RE: Editing fields in bulk

2007-09-04 Thread Hartleigh Burton
I could use the same thing... just looking through the documentation there is a replace() function. Maybe do a backup/restore to a test database before doing this on your live system... UPDATE `tablename` SET `fieldname`=REPLACE(tablename.fieldname,'US- Complete','US Complete') WHERE `fieldname` L