ddl
create table dept_emp(
emp_no int not null,
dept_no char(4) not null,
from_date date not null,
to_date date not null,
primary key (emp_no)
);
时间类型作为条件但没有指定单引号时, 表现不一致
-- mysql不带单引号未报错, 但结果不对
-- doris没报错也没输出
select * from dept_emp where from_date > 2011-01-01;
字符串类型作为条件但没有指定单引号时, 表现一致
-- mysql: [42S22][1054] Unknown column 'AAA' in 'where clause'
-- doris: errCode = 2, detailMessage = Unknown column 'AAA' in 'table list'
select * from dept_emp where dept_no > AAA;