I don't know if there's an easy way to do it using a query, but you can use a small php script. Borrowing a nice script that Adrian posted in this thread
https://vborg.vbsupport.ru/showthread.php?t=266166 , you could do something like this:
PHP Code:
<?php
error_reporting(E_ALL ^ E_NOTICE ^ 8192);
require('./global.php');
$result = $vbulletin->db->query_read("SELECT postid, pagetext FROM " . TABLE_PREFIX . "post");
while ($post = $vbulletin->db->fetch_array($result)) {
$new = preg_replace("#\[/?(color|size|font)(=\s*\"?.*?\"?\s*)?]#i", '', $post['pagetext']);
if ($new != $post['pagetext'])
{
$vbulletin->db->query_write(fetch_query_sql(
array('pagetext' => $new),
'post',
'WHERE postid = ' . $post['postid']
));
}
}
die('Done');
(I tried this out, but you'd probably want to back up the db before running this, just in case).