问题解决!分享 仓库管理
做了一个简易的仓库管理程序,在入库,出库 和库存。入库和出库已做好,这个库存不知怎样做?请过来人帮帮手,谢谢!e.g: 入库表:仓库名,货品编码,货品名,数量,供应商
出库表:仓库名,货品编码,货品名,数量
库存表:仓库名,货品编码,数量
我想在程序中查看库存。谢谢!
[此贴子已经被作者于2007-11-20 11:50:01编辑过]
问题解决了,和大家分享一下。如果大家有其他想法,请不要保留!谢谢
strSqlIn = "create view v_Instorage as select bldg, code, sum(qty) as inqty from instorage group by bldg, code"
strSqlOut = "create view v_Outstorage as select bldg, code, sum(qty) as outqty from outstorage group by bldg, code"
strSqlLeavings = "create view v_Leavings as select a1.bldg,a1.code,a1.inqty-a2.outqty as qtyleavings from v_instorage a1,v_outstorage where a1.bldg = a2.bldg and a1.code = a2.code"
[此贴子已经被作者于2007-11-20 15:18:58编辑过]