/*
================================================================================
档案代号:vnb_file
档案名称:aps 单据追溯维护档
档案目的:
上游档案:
下游档案:
============.========================.==========================================
*/
create table vnb_file
(
vnb01       varchar2(60) DEFAULT '' NOT NULL, /*供给来源单据编号*/
vnb02       number(15,3),            /*需求来源需求数量                       */
vnb03       varchar2(60) DEFAULT '' NOT NULL, /*需求来源单据编号*/
vnb04       number(1),               /*需求订单                               */
vnb05       number(15,3),            /*预计供给数量                           */
vnb06       number(1),               /*采购令 or 制令                         */
vnb07       number(15,3),            /*供给最大量                             */
vnb08       number(1),               /*锁定                                   */
vnb09       varchar2(40)             /*料号                                   */
);

create unique index vnb_pk on vnb_file (vnb01,vnb03);
alter table vnb_file add  constraint vnb_pk primary key  (vnb01,vnb03) enable validate;
grant select on vnb_file to public;
grant index on vnb_file to public;
grant update on vnb_file to public;
grant delete on vnb_file to public;
grant insert on vnb_file to public;