sql name starts with code example
Example 1: sql print all names that start with a given letter
select employee_name
from employees
where employee_name LIKE 'A%' OR employee_name LIKE 'B%'
order by employee_name
Example 2: sql string starts with
-- Case insensitive
SELECT * FROM my_table WHERE upper(my_column) LIKE 'SEARCHED %'; -- starts with
SELECT * FROM my_table WHERE upper(my_column) LIKE '% SEARCHED'; -- ends with
SELECT * FROM my_table WHERE upper(my_column) LIKE '%SEARCHED%'; -- contains