我正在尝试执行此查询,但它不喜欢它“它抛出以下异常”溢出一个 int 列。超出最大整数值。”不知道这里缺少什么
select * from Schedwin.SEVT where
ltrim(Resid)=345032 and type=5 or (type = 4 and subactid = 4)
or
(TYPE = 0)and (USER2='02-Force OT')
and ltrim(SEVT.t_start) <= 1215208800
and ltrim(sevt.t_start) <= 1215207800
order by SEVT.TYPE
我不好的 t_start 数据类型是 char 所以我修改了我的查询,如下所示,它可以工作
select * from Schedwin.SEVT where
ltrim(Resid)=345032 and type=5 or (type = 4 and subactid = 4)
or
(TYPE = 0)and (USER2='02-Force OT')
and ltrim(SEVT.t_start) <= '1215208800'
and ltrim(sevt.t_start) <= '1215207800'
order by SEVT.TYPE