ASP.NET2.0是建立在微软新一代.NET平台架构上,利用普通语言运行时(Common Language Runtime)在服务器后端为用户提供建立强大的企业级Web应用服务的编程框架。ASP.NET2.0主要包括WebForm和WebService两种编程模型。前者为用户提供建立功能强大、外观丰富的基于表单的可编程Web页面。后者通过对HTTP、HTML、SOAP、WSDL等Internet标准的支持,提供在异构网络环境下获取远程服务、连接远程设备和交互远程应用的编程界面。
string YearSum="SELECT 车辆, 月份, sum(汽油费合计) AS 总汽油费, sum(公里合计) AS 总公里数"
+ " FROM (SELECT 车辆, month(出车时间) AS 月份, sum(汽油费) AS 汽油费合计, sum(止公里数-起公里数) AS 公里合计"
+ " FROM CTCLSYB"
+ " WHERE 车辆=′" + DropDownList1.SelectedValue + "′and year(出车时间)=′"+DropDownList2.SelectedValue+"′"
+ "GROUP BY month(出车时间), 车辆"
+ "UNION select 车辆,month(出车时间) as 月份,sum(汽油费) AS 汽油费合计, sum(止公里数-起公里数) AS 公里合计"
+ "FROM JTCLSYB"
+ "WHERE 车辆=′"+DropDownList1.SelectedValue+"′and year(出车时间)=′"+DropDownList2.SelectedValue+"′"
+ "group BY month(出车时间), 车辆) AS A"
+ "GROUP BY 月份, 车辆"); DataTable dt = DataLayer.Select("SELECT 车辆, 月份, sum(汽油费合计) AS 总汽油费, sum(公里合计) AS 总公里数"
+ " FROM (SELECT 车辆, month(出车时间) AS 月份, sum(汽油费) AS 汽油费合计, sum(止公里数-起公里数) AS 公里合计"
+ " FROM CTCLSYB"
+ " WHERE 车辆=′" + DropDownList1.SelectedValue + "′and year(出车时间)=′" + DropDownList2.SelectedValue + "′"
+ " GROUP BY month(出车时间), 车辆"
+ " UNION select 车辆, month(出车时间) as月份,sum(汽油费) AS 汽油费合计, sum(止公里数-起公里数) AS 公里合计"
+ " FROM JTCLSYB"
+ " WHERE 车辆=′"+DropDownList1.SelectedValue + "′and year(出车时间)=′"+DropDownList2.SelectedValue+"'"
+ " group BY month(出车时间), 车辆) AS A"
+ " GROUP BY 月份, 车辆");
4.5 系统管理