SCO供应链协同

## 数据表：T_RPM_ACCOUNT(返利账户)

### T_RPM_ACCOUNT(返利账户)：描述

名称 | T_RPM_ACCOUNT(返利账户)
代码 | T_RPM_ACCOUNT
注释 |
模型 | SCO供应链协同
主键 | PK_RPM_ACCOUNT

### T_RPM_ACCOUNT(返利账户)：列规格定义

名称 | 代码 | 数据类型 | 长度 | 强制 | 注释
主键ID | FID | int |  | TRUE |
账号 | FNUMBER | nvarchar(80) | 80 | TRUE |
状态 | FDOCUMENTSTATUS | char(1) | 1 | TRUE |
是否系统预置 | FISSYSTEMSET | char(1) | 1 | TRUE |
是否默认账户 | FISDEFAULT | char(1) | 1 | TRUE |
创建人 | FCREATORID | int |  | TRUE |
创建日期 | FCREATEDATE | datetime |  | FALSE |
修改人 | FMODIFIERID | int |  | TRUE |
修改日期 | FMODIFYDATE | datetime |  | FALSE |
禁用状态 | FFORBIDSTATUS | char(1) | 1 | TRUE | 'A'否 ‘B'是
审核人 | FAPPROVERID | int |  | TRUE |
审核日期 | FAPPROVEDATE | datetime |  | FALSE |
禁用人 | FFORBIDDERID | int |  | TRUE |
禁用日期 | FFORBIDDATE | datetime |  | FALSE |

### T_RPM_ACCOUNT(返利账户)：脚本代码

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_RPM_ACCOUNTBALANCE') and o.name = 'FK_T_RPM_AC_REFERENCE_T_RPM_AC')
alter table T_RPM_ACCOUNTBALANCE
drop constraint FK_T_RPM_AC_REFERENCE_T_RPM_AC
go
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_RPM_ACCOUNT_L') and o.name = 'FK_T_RPM_AC_REFERENCE_T_RPM_AC')
alter table T_RPM_ACCOUNT_L
drop constraint FK_T_RPM_AC_REFERENCE_T_RPM_AC
go
if exists (select 1
from sysindexes
where id = object_id('T_RPM_ACCOUNT')
and name = 'IDX_RPM_ACCOUNT_NUM'
and indid > 0
and indid < 255)
drop index T_RPM_ACCOUNT.IDX_RPM_ACCOUNT_NUM
go
if exists (select 1
from sysobjects
where id = object_id('T_RPM_ACCOUNT')
and type = 'U')
drop table T_RPM_ACCOUNT
go
/*==============================================================*/
/* Table: T_RPM_ACCOUNT */
/*==============================================================*/
create table T_RPM_ACCOUNT (
FID int not null default 0,
FNUMBER nvarchar(80) not null default '',
FDOCUMENTSTATUS char(1) not null default 'Z',
FISSYSTEMSET char(1) not null default '0',
FISDEFAULT char(1) not null default '0',
FCREATORID int not null default 0,
FCREATEDATE datetime null,
FMODIFIERID int not null default 0,
FMODIFYDATE datetime null,
FFORBIDSTATUS char(1) not null default 'A',
FAPPROVERID int not null default 0,
FAPPROVEDATE datetime null,
FFORBIDDERID int not null default 0,
FFORBIDDATE datetime null,
constraint PK_RPM_ACCOUNT primary key (FID)
)
go
declare @CurrentUser sysname
select @CurrentUser = user_name()
execute sp_addextendedproperty 'MS_Description',
'''A''否 ‘B''是',
'user', @CurrentUser, 'table', 'T_RPM_ACCOUNT', 'column', 'FFORBIDSTATUS'
go
/*==============================================================*/
/* Index: IDX_RPM_ACCOUNT_NUM */
/*==============================================================*/
create index IDX_RPM_ACCOUNT_NUM on T_RPM_ACCOUNT (
FNUMBER ASC
)
go

### T_RPM_ACCOUNT(返利账户)：键值定义

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

### T_RPM_ACCOUNT(返利账户)：索引定义

名称 | 代码 | 唯一的 | 群集器 | 主要的 | 外键 | 候选键 | 表格
IDX_RPM_ACCOUNT_NUM | IDX_RPM_ACCOUNT_NUM | FALSE | FALSE | FALSE | FALSE | FALSE | T_RPM_ACCOUNT(返利账户)

上一页

主页

下一页