vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| So I have a field called "fulltext" that is of medium text type. I'm trying to apply a global text string replace, and in the past I have had success with the following syntax: update [table_name] set [field_name] = replace( [field_name], '[string_to_find]', '[string_to_replace]' ); I can apply this with no problem to a varchar field, however the global replacement that I need to execute is on a mediumtext type -- so far I'm generating 1064 MySQL errors when I run this: update `mos_content` SET fulltext = REPLACE(fulltext,'this text','that text'); Thanks for any suggestions! Chuck |
| |||
| On 30 Apr, 16:45, Chuck W1CEW <cewyat...@gmail.com> wrote: > So I have a field called "fulltext" that is of medium text type. I'm > trying to apply a global text string replace, and in the past I have > had success with the following syntax: > > update [table_name] > set [field_name] = replace( > [field_name], > '[string_to_find]', > '[string_to_replace]' > ); > > I can apply this with no problem to a varchar field, however the > global replacement that I need to execute is on a mediumtext type -- > so far I'm generating 1064 MySQL errors when I run this: > > update `mos_content` > SET fulltext = > REPLACE(fulltext,'this text','that text'); > > Thanks for any suggestions! > > Chuck My first suggestion is that you post the error message. The message tells us what is wrong. That is why they have them! |
| |||
| Chuck W1CEW wrote: > So I have a field called "fulltext" that is of medium text type. I'm > trying to apply a global text string replace, and in the past I have > had success with the following syntax: > > update [table_name] > set [field_name] = replace( > [field_name], > '[string_to_find]', > '[string_to_replace]' > ); > > I can apply this with no problem to a varchar field, however the > global replacement that I need to execute is on a mediumtext type -- > so far I'm generating 1064 MySQL errors when I run this: > > update `mos_content` > SET fulltext = > REPLACE(fulltext,'this text','that text'); > > Thanks for any suggestions! > > Chuck > run that baby like this: update `mos_content` SET `fulltext` = REPLACE(`fulltext`,'this','that') it'll work. |
| ||||
| On Apr 30, 12:12 pm, lark <ham...@sbcglobal.net> wrote: > run that baby like this: > update `mos_content` SET `fulltext` = REPLACE(`fulltext`,'this','that') > > it'll work. Woo hoo! That works. Thanks VERY much! |
| Thread Tools | |
| Display Modes | |
|
|