我的问题:选择除Clerk之外的所有员工的所有数据。按他们的姓氏排序 名称
我的查询:
select * from employees WHERE job_id NOT like '%CLERK' AND order by last_name
但它不起作用
答案 0 :(得分:2)
删除AND
select * from employees
WHERE job_id NOT like '%CLERK'
order by last_name
根据评论,使用伪代码
select * from employees
WHERE job_id != 'CLERKS'
AND DateAppointedFielName BETWEEN StartDate AND EndDate
order by last_name