SCO供应链协同

## 数据表：T_DRP_REORDERBILL(补货单)

### T_DRP_REORDERBILL(补货单)：描述

名称 | T_DRP_REORDERBILL(补货单)
代码 | T_DRP_REORDERBILL
注释 | 补货单
模型 | SCO供应链协同
主键 | PK_DRP_REORDERBILL

### T_DRP_REORDERBILL(补货单)：列规格定义

名称 | 代码 | 数据类型 | 长度 | 强制 | 注释
主键 | FID | int |  | TRUE |
单据类型 | FBILLTYPEID | varchar(36) | 36 | TRUE |
单据编号 | FBILLNO | nvarchar(30) | 30 | TRUE |
供货渠道 | FSUPPLYCHANNELID | int |  | TRUE |
供货组织 | FSUPPLYORGID | int |  | TRUE |
申请人 | FAPPUSERID | int |  | TRUE |
申请日期 | FAPPDATE | datetime |  | FALSE |
结算币别 | FSETTLECURRID | int |  | TRUE |
单据状态 | FDOCUMENTSTATUS | char(1) | 1 | TRUE |
创建人 | FCREATORID | int |  | TRUE |
创建日期 | FCREATEDATE | datetime |  | FALSE |
修改人 | FMODIFIERID | int |  | TRUE |
修改日期 | FMODIFYDATE | datetime |  | FALSE |
审核人 | FAPPROVERID | int |  | TRUE |
审核日期 | FAPPROVEDATE | datetime |  | FALSE |
关闭状态 | FCLOSESTATUS | char(1) | 1 | TRUE | 状态字段 A：未关闭 B：已关闭
关闭人 | FCLOSERID | int |  | TRUE |
关闭日期 | FCLOSEDATE | datetime |  | FALSE |
作废状态 | FCANCELSTATUS | char(1) | 1 | TRUE | 状态字段 A：未作废 B：已作废
作废人 | FCANCELLERID | int |  | TRUE |
作废日期 | FCANCELDATE | datetime |  | FALSE |
是否含税 | FISINCLUDEDTAX | char(1) | 1 | TRUE |
备注 | FNOTE | nvarchar(255) | 255 | TRUE |

### T_DRP_REORDERBILL(补货单)：脚本代码

if exists (select 1
from sys.sysreferences r join sys.sysobjects o on (o.id = r.constid and o.type = 'F')
where r.fkeyid = object_id('T_DRP_REORDERBILLENTRY') and o.name = 'FK_T_DRP_RE_REFERENCE_T_DRP_RE')
alter table T_DRP_REORDERBILLENTRY
drop constraint FK_T_DRP_RE_REFERENCE_T_DRP_RE
go
if exists (select 1
from sysindexes
where id = object_id('T_DRP_REORDERBILL')
and name = 'IDX_DRP_REORDERBILL_ORG'
and indid > 0
and indid < 255)
drop index T_DRP_REORDERBILL.IDX_DRP_REORDERBILL_ORG
go
if exists (select 1
from sysindexes
where id = object_id('T_DRP_REORDERBILL')
and name = 'IDX_DRP_REORDERBILL_NUM'
and indid > 0
and indid < 255)
drop index T_DRP_REORDERBILL.IDX_DRP_REORDERBILL_NUM
go
if exists (select 1
from sysindexes
where id = object_id('T_DRP_REORDERBILL')
and name = 'IDX_DRP_REORDERBILL_DATE'
and indid > 0
and indid < 255)
drop index T_DRP_REORDERBILL.IDX_DRP_REORDERBILL_DATE
go
if exists (select 1
from sysobjects
where id = object_id('T_DRP_REORDERBILL')
and type = 'U')
drop table T_DRP_REORDERBILL
go
/*==============================================================*/
/* Table: T_DRP_REORDERBILL */
/*==============================================================*/
create table T_DRP_REORDERBILL (
FID int not null default 0,
FBILLTYPEID varchar(36) not null default '',
FBILLNO nvarchar(30) not null default '',
FSUPPLYCHANNELID int not null default 0,
FSUPPLYORGID int not null default 0,
FAPPUSERID int not null default 0,
FAPPDATE datetime null,
FSETTLECURRID int not null default 0
constraint CKC_FSETTLECURRID_T_DRP_RE check (FSETTLECURRID >= 0),
FDOCUMENTSTATUS char(1) not null default 'Z',
FCREATORID int not null default 0,
FCREATEDATE datetime null,
FMODIFIERID int not null default 0,
FMODIFYDATE datetime null,
FAPPROVERID int not null default 0,
FAPPROVEDATE datetime null,
FCLOSESTATUS char(1) not null default 'A',
FCLOSERID int not null default 0,
FCLOSEDATE datetime null,
FCANCELSTATUS char(1) not null default 'A',
FCANCELLERID int not null default 0,
FCANCELDATE datetime null,
FISINCLUDEDTAX char(1) not null default '0',
FNOTE nvarchar(255) not null default '',
constraint PK_DRP_REORDERBILL primary key (FID)
)
go
declare @CurrentUser sysname
select @CurrentUser = user_name()
execute sp_addextendedproperty 'MS_Description',
'补货单',
'user', @CurrentUser, 'table', 'T_DRP_REORDERBILL'
go
declare @CurrentUser sysname
select @CurrentUser = user_name()
execute sp_addextendedproperty 'MS_Description',
'状态字段
A：未关闭
B：已关闭',
'user', @CurrentUser, 'table', 'T_DRP_REORDERBILL', 'column', 'FCLOSESTATUS'
go
declare @CurrentUser sysname
select @CurrentUser = user_name()
execute sp_addextendedproperty 'MS_Description',
'状态字段
A：未作废
B：已作废',
'user', @CurrentUser, 'table', 'T_DRP_REORDERBILL', 'column', 'FCANCELSTATUS'
go
/*==============================================================*/
/* Index: IDX_DRP_REORDERBILL_DATE */
/*==============================================================*/
create index IDX_DRP_REORDERBILL_DATE on T_DRP_REORDERBILL (
FAPPDATE ASC
)
go
/*==============================================================*/
/* Index: IDX_DRP_REORDERBILL_NUM */
/*==============================================================*/
create index IDX_DRP_REORDERBILL_NUM on T_DRP_REORDERBILL (
FBILLNO ASC
)
go
/*==============================================================*/
/* Index: IDX_DRP_REORDERBILL_ORG */
/*==============================================================*/
create index IDX_DRP_REORDERBILL_ORG on T_DRP_REORDERBILL (
FSUPPLYORGID ASC,
FAPPDATE ASC
)
go

### T_DRP_REORDERBILL(补货单)：键值定义

名称 | 代码 | 主要的
PK_DRP_REORDERBILL | PK_DRP_REORDERBILL | TRUE

### T_DRP_REORDERBILL(补货单)：索引定义

名称 | 代码 | 唯一的 | 群集器 | 主要的 | 外键 | 候选键 | 表格
IDX_DRP_REORDERBILL_DATE | IDX_DRP_REORDERBILL_DATE | FALSE | FALSE | FALSE | FALSE | FALSE | T_DRP_REORDERBILL(补货单)
IDX_DRP_REORDERBILL_NUM | IDX_DRP_REORDERBILL_NUM | FALSE | FALSE | FALSE | FALSE | FALSE | T_DRP_REORDERBILL(补货单)
IDX_DRP_REORDERBILL_ORG | IDX_DRP_REORDERBILL_ORG | FALSE | FALSE | FALSE | FALSE | FALSE | T_DRP_REORDERBILL(补货单)

上一页

主页

下一页