Thanks, I was hoping it would be much less than that so that manually editing them individually wouldn’t be too tedious. But for that many one would need to have exceptional perseverance.
You will definitely want to save a backup before doing anything potentially destructive in the CLI. And it would be best to hone the pattern until the count value is the same before changing any content.
You didn’t show any in your example bbcode, so I didn’t think of it at the time, but you should run that query again using ILIKE (case insensitive) just in case you have any
[QUOTE] tags. (hopefully not)
My ActiveRecord foo is less than I’d like it to be, but Inside the rails console try
Post.where("cooked REGEXP ?", '\[quote').count
If the results don’t match it will need some refinements.