SQL tricks
September 10, 2022
How to find records where text field does not contains digits?
select * from names where name not rlike '[0-9]';
PostgreSQL (using ~ operator):
select * from names where not(name ~ '\d+');
Transact SQL & Oracle SQL (using not like):
select * from names where name not like '%[0-9]%';