资源描述:
《一个进销存数据库设计的例子》由会员上传分享,免费在线阅读,更多相关内容在行业资料-天天文库。
1、一个进销存数据库设计的例子一个进销存数据库设计的例子.01.CREATETABLEuser(02.User_Idvarchar(6),03.User_Pwdvarchar(8)NULL,04.Again_Pwdvarchar(8)NULL,05.Bel_Groupvarchar(3)NULL,06.Div_Typevarchar(1)NULL,07.User_Authvarchar(1)NULL,08.Auth_Typevarchar(1)NULL,09.User_Statusvarchar(1)NULL,10.Create_Uservarchar(6)NULL,
2、11.Create_Datevarchar(7)NULL,12.Create_Timevarchar(6)NULL,13.Appr_Uservarchar(6)NULL,14.Appr_Datevarchar(7)NULL,15.Appr_Timevarchar(6)NULL,16.Pwd_Datevarchar(7)NULL,17.Err_CountfloatNULL,18.Use_eJCICvarchar(1)NULL19.)20.CREATETABLESupplier/*供应商表*/21.(22.Supplier_IDintIDENTITY(1,1)NOTN
3、ULL,/*供应商编号,主键*/23.Namevarchar(250)NOTNULL,/*供应商名称*/24.Addressvarchar(250)NOTNULL,/*地址*/25.Phonevarchar(25)NULL,/*电话*/26.Faxvarchar(25)NULL,/*传真*/27.PostalCodevarchar(10)NULL,/*邮编*/28.ConstactPersonvarchar(20)NULL/*联系人*/29.)30.31.CREATETABLECustomer/*客户表*/32.(33.Customer_IDintIDENTITY
4、(1,1)NOTNULL,/*客户编号,主键*/34.Namevarchar(250)NOTNULL,/*客户名称*/35.Addressvarchar(250)NOTNULL,/*地址*/36.Phonevarchar(25)NULL,/*电话*/37.Faxvarchar(25)NULL,/*传真*/38.PostalCodevarchar(10)NULL,/*邮编*/39.ConstactPersonvarchar(20)NULL/*联系人*/40.)41.42.CREATETABLEDept/*部门表*/43.(44.Dept_IDintIDENTITY(
5、1,1)NOTNULL,/*部门编号,主键*/45.Namevarchar(30)NOTNULL,/*名称*/46.Remarkvarchar(250)NOTNULL/*描述,备注*/47.)48.49.CREATETABLEDept_Supplier/*部门--供应商表*/50.(51.Dept_IDintNOTNULL,/*部门编号,主键,外键(参照DEPT表)*/52.Supplier_IDintNOTNULL/*供应商编号,主键,外键(参照SUPPLIER表)*/53.)54.55.CREATETABLEDept_Customer/*部门--客户表*/56
6、.(57.Dept_IDintNOTNULL,/*部门编号,主键,外键(参照DEPT表)*/58.Customer_IDintNOTNULL/*客户编号,主键,外键(参照SUPPLIER表)*/59.)60.61.CREATETABLEStoreHouse/*仓库表*/62.(63.StoreHouse_IDintIDENTITY(1,1)NOTNULL,/*仓库编号,主键*/64.Addressvarchar(250)NOTNULL,/*地址*/65.Phonevarchar(25)NULL,/*电话*/66.Employee_IDINTNOTNULL,/*仓库
7、保管,外键(参照EMPLOYEE表)*/67.CreateDatedatetimeNULL/*仓库成立时间*/68.)69.70.CREATETABLEProductClass/*商品总分类表*/71.(72.ProductClass_IDintIDENTITY(1,1)NOTNULL,/*商品总分类编号,主键*/73.Namevarchar(30)NOTNULL,/*商品分类名称*/74.Employee_IDINTNOTNULL,/*建分类人,外键(参照EMPLOYEE表)*/75.CreateDatedatetimeNULL,/*建分类时间*/76.Rema
8、rkvar