Mediawiki markup text is stored in the old_text field, which is a mediumblob type. You can request it, like any other text field. MySQL will output your string to the binary for the query. Please note that this is a case sensitive search!
select old_id from text where old_text like "%string%";
If you need case insensitivity, you need to apply the appropriate character set with case insensitivity:
SELECT old_id from text where CONVERT(old_text USING latin1) like '%STRing%';
Remember that if your table is small, these queries will take a lot of time.
source share