I have a bunch url that has a string either has
hotel+4 digit number: hotel1234 or slash+4digit.html: /1234.html
Is there a regex to extract
You can try the REGEXP
SELECT * FROM Table WHERE ColumnName REGEXP '^[0-9]{4}$'
or
SELECT * FROM Table WHERE ColumnName REGEXP '^[[:digit:]]{4}$';