界面元素查询语句计算页数SQL中增加汇总值描述
来源:互联网 发布:淘宝 桌游 编辑:程序博客网 时间:2024/06/01 10:49
界面如下图展示效果:
SQL语句写法如下:
selectceiling(count(*)/10.0),'ROOT=【Number:'+STR(COUNT(*))
+'】 【Import ct.:'+(cast(sum(FirstInStorageWeight)asvarchar(30)))
+'】 【Estimate ct.:'+(cast(sum(EstimateWeight)asvarchar(30)))
+'】 【Current ct.:'+(cast(sum(CurrentWeight)asvarchar(30)))+'】'
from (selectx.RecordID,x.DiamondID,x.OriginalWeight,x.FirstInStorageWeight,x.EstimateWeight,x.CurrentWeight
from DiamondDB.dbo.DiamondStock x
left joinDiamondDB.dbo.DiamondQuality y on x.Quality=y.QualityID
left joinDiamondDB.dbo.DiamondShape z on x.Shape=z.ShapeID
left joinDiamondDB.dbo.DiamondClarity a on x.Clarity=a.ClarityID
left joinDiamondDB.dbo.DiamondColor b on x.Color=b.ColorID
left joinDiamondDB.dbo.DiamondSymmetry d on x.Symmetry=d.SymmetryID
left joinDiamondDB.dbo.DiamondFluorescence f on x.Fluorescence=f.FluorescenceID
left joinDiamondDB.dbo.OriginalDiamondInStorageDetails o on x.DiamondID=o.DiamondID
left joinDiamondDB.dbo.ImportListMaster p on o.ListID=p.ListID ando.SerialNumber=p.SerialNumber
left joinDiamondDB.dbo.Supplier q on p.SupplierID=q.SupplierID
left joinDiamondDb.dbo.ProcessInfo u on x.ProcessID=u.ProcessID
left joinDiamondDB.dbo.ProcessType v on u.TypeID=v.TypeID
left joinDiamondPlatformDB.dbo.T_Employee te on x.EmpID=te.EmpID
left joinDiamondPlatformDB.dbo.T_Department td on te.DepID=td.DepID
where x.DiamondID=@Diamond_ and x.PackageNumber like '%'+@PackageNumber_+'%'and x.Shape=@shpeid_ and x.Color=@colorid_
andx.Clarity=@clarityid_ and x.Symmetry=@symmetryid_ andx.Fluorescence=@fluorescenceid_ and x.Quality=@qualityid_
andx.FirstInStorageWeight between @num1_ and @num2_ andx.ProcessStatus=@ProcessStatus_ and x.StorageStatus=@StorageStatus_
and o.ListID like'%'+@ListID_+'%' and o.SerialNumber like '%'+@SerialNumber_+'%' andx.IsFM=@IsFM_ and x.IsUrgent=@IsUrgent_
andq.SupplierID=@SupplierID_ and td.DepID=@DepID_ and te.EmpID=@EmpID_) t;
- 界面元素查询语句计算页数SQL中增加汇总值描述
- SQL查询语句汇总
- sql查询语句汇总
- 在查询语句中增加序号字段(sql server)
- sql查询语句select汇总
- 【SQL】SQL中的数据查询语句汇总
- sql查询中,增加序号
- sql语句实现增加表、字段描述性文字
- 界面元素构件查询SQL的生成
- php中sql语句汇总
- SqlServer2005高效分页sql查询语句汇总
- SqlServer2005高效分页sql查询语句汇总
- sql server 编程查询语句汇总
- Access常用sql基本查询语句汇总
- SQL语句中计算百分比
- SQL迅速增加表中记录语句
- Oracle, SQL Server, My SQL数据分页查询语句汇总
- SQL语句查询结果额外添加一列序号自动增加
- nanomsg的使用与分析
- C++Primer学习之四初始化
- 界面上单元格的可操作性和背景颜色根据某一个单元格值的变化而发生改变
- 总结2015,启航2016
- 使弹出框的标题显示为父窗体上选中行的内容
- 界面元素查询语句计算页数SQL中增加汇总值描述
- 隐马尔可夫模型(HMM)攻略
- 实现界面全选效果
- linux例行性命令
- 2、决策树ID3、C4.5、CART
- HTML5开发移动web应用——SAP UI5篇(4)
- 1011. A+B和C
- chromephp:chrome浏览器php控制台调试工具使用指南
- find命令笔记