捷信达酒店管理系统其他消费明细SQL查询语句
select SUM(Amount) from gsfoliodetail a , ( select a.pcode,a.cname from gsitem a where a.code like ‘0%‘ and len(a.pcode) = 6 ) b where ( substring(a.itempcode,1,6) = b.pcode)and pcode like ‘001010%‘ select * from gsfoliodetail a , ( select a.pcode,a.cname from gsitem a where a.code like ‘0%‘ and len(a.pcode) = 6 ) b where ( substring(a.itempcode,1,6) = b.pcode)and pcode like ‘001010%‘
原文地址:https://www.cnblogs.com/landv/p/9259847.html
时间: 2024-10-07 05:01:00