add batch remove batch split batch comment selection show hidden batches hide batch highlight batch
db<>fiddle
donate feedback about
By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
create table tbl (
id int,
text varchar(100)
);

insert into tbl values
(1, '</table>
</li>
</ul>'),
(2, '< /table>
< /li>
< /ul>');
Records: 2  Duplicates: 0  Warnings: 0
select * from tbl;
id text
1 </table>


</li>
</ul>
2 < /table>


< /li>
< /ul>
select
REGEXP_REPLACE(
text
,'<[[:blank:][:space:]]*\/table>[[:blank:][:space:]]+<[[:blank:][:space:]]*\/li>[[:blank:][:space:]]+<[[:blank:][:space:]]*\/ul>[[:blank:][:space:]]*'
,'</table>'
) text
from tbl;
text
</table>
</table>
update tbl
set text = REGEXP_REPLACE(
text
,'<[[:blank:][:space:]]*\/table>[[:blank:][:space:]]+<[[:blank:][:space:]]*\/li>[[:blank:][:space:]]+<[[:blank:][:space:]]*\/ul>[[:blank:][:space:]]*'
,'</table>'
)
Rows matched: 2  Changed: 2  Warnings: 0
select * from tbl;
id text
1 </table>
2 </table>