/*
================================================================================
档案代号:adh_file
档案名称:集团拨入单单头档
档案目的:
上游档案:
下游档案:
============.========================.==========================================
*/
create table adh_file
(
adh00       varchar2(1),             /*调拨类型                               */
adh01       varchar2(16) NOT NULL,   /*拨入单号                               */
adh02       date,                    /*单据日期                               */
adh03       varchar2(10),            /*员工编号                               */
adh04       varchar2(10),            /*部门编号                               */
adh05       varchar2(255),           /*备注                                   */
adh06       date,                    /*过帐日期                               */
adh07       varchar2(1),             /*状况码                                 */
adhmksg     varchar2(1),             /*是否签核                               */
adhsign     varchar2(4),             /*签核等级                               */
adhdays     number(5),               /*签核完成天数                           */
adhprit     number(5),               /*签核优先等级                           */
adhsseq     number(5),               /*已签核顺序                             */
adhsmax     number(5),               /*应签核顺序                             */
adhconf     varchar2(1),             /*确认                                   */
adhprsw     number(5),               /*列印次数                               */
adhacti     varchar2(1),             /*资料有效码                             */
adhpost     varchar2(1),             /*过帐否                                 */
adhuser     varchar2(10),            /*资料所有者                             */
adhgrup     varchar2(10),            /*资料所有部门                           */
adhmodu     varchar2(10),            /*资料修改者                             */
adhdate     date                     /*最近修改日                             */
);

create        index adh_02 on adh_file (adh02,adh01);
create unique index adh_pk on adh_file (adh01);
alter table adh_file add  constraint adh_pk primary key  (adh01) enable validate;
grant select on adh_file to public;
grant index on adh_file to public;
grant update on adh_file to public;
grant delete on adh_file to public;
grant insert on adh_file to public;