A newbie in SQL asking about functions

Viewed 24

How can I find data that dont end with letter 'g' without using NOT LIKE function, please help

2 Answers

select * from table where right(column, 1) != 'g'

Since you asked how to do it using "not like," I'll answer that. The function version provided by @Zoories would be more efficient. This works at w3schools.com

SELECT * FROM Customers where CustomerName not like '%g';
Related