摘要: SELECT *FROM (SELECT DISTINCT yy, mm, Org_id, bus_id FROM Monthorgsell) t1WHERE (NOT EXISTS (SELECT DISTINCT yy, mm, Org_id, bus_id FROM MonthorgPlan AS t2 WHERE t1.yy = t2.yy AND t1.mm = t2.mm AND t1... 阅读全文
posted @ 2010-03-27 10:09 bingege 阅读(476) 评论(0) 推荐(0) 编辑
摘要: 在sql server 的northwide 中建立主表: create table sell_main( sell_id char(10),cust_name char(10) Primary key(sell_id) ) go 建立从表: create table sell_item( sell_id char(10),inv char(10) ,amt float,qty float Pr... 阅读全文
posted @ 2010-03-27 10:01 bingege 阅读(2216) 评论(0) 推荐(0) 编辑