SQL Query or Mod to mass modify all posts in a particular Board

Started by sunny17, August 20, 2017, 08:03:58 PM

Previous topic - Next topic

sunny17

Hi
Is there anyway such as sql query or a mod to mass change posts to delete "[hide]" tag from all the topics in a certain board.
I tried searching the forum but couldnt find anything related.

Appreciate your help!
Thanks

Kindred

You would have to do a sql query...



UPDATE smf_messages SET body=REPLACE(body,'[hide]','');
UPDATE smf_messages SET body=REPLACE(body,'[/hide]','');
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

sunny17

Thanks for the quick reply
Will this modify all messages from all boards ?
I just need to modify from id_board 10. How would i include this?

Thanks

Kindred

That I don't know off the top of my head... I would have to get to a real computer and look at the actual database...    it would require a WHERE clause added to the end, but I don't know what the field name is
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

sunny17

Ah i was able to test and execute code below and worked perfectly

UPDATE `smf_messages` SET `body`=REPLACE(`body`,'[/hide]','') WHERE `id_board` = 10

Thanks again for your assistance
Topic can now be closed

Advertisement: