SELECT branch.branch_name,cls.cls_name,cls.cls_no, sum(detail.sub_amt) as sub_amt , sum(detail.sub_qty) as sub_qty, CONVERT(varchar(100), detail.oper_date, 23) as oper_date from bi_t_item_info as item, bi_t_cls_info as cls, pos_t_sale_detail as detail, bi_v_branch_info as branch where cls.cls_no=item.cls_no and detail.item_no=item.item_no and branch.area_no=detail.branch_jg and branch.branch_name like '赤峰%店' and branch.branch_name like '赤峰平庄二店' and detail.oper_date between '2017-4-1' and '2017-4-2' and cls_no like '005001' or '005002' or '005004' or '005013' or '005014' or '00515' or '005016' or '009001' or '009002' or '009003' or '009004' or '009005' group by branch.branch_name , cls.cls_name ,detail.oper_date , ====================== 服务器: 消息 4145,级别 15,状态 1,行 12 在应使用条件的上下文(在 'or' 附近)中指定了非布尔类型的表达式。 求大神解答 谢谢 |
最佳回答 |
||||
0
|
|
|||
0
|
|
|||
0
|
|
|||
0
|
|
|||
0
|
|
|||
0
|
|
|||
0
|
|