CONTRACT

Each row of this table represents a Contract. A Contract is part of a Store, and represents terms and conditions that may be associated with OrderItems. Such as prices, minimum quantities, and who can use the Contract.

Column Descriptions:

NameTypeDescription
CONTRACT_IDBIGINT NOT NULLUnique identifier for a contract. Foreign key to TRADING_ID in the TRADING database table.
MAJORVERSIONINTEGER NOT NULL DEFAULT 1Major version number of the Contract.
MINORVERSIONINTEGER NOT NULL DEFAULT 0Minor version number of the Contract.
NAMEVARCHAR (200) NOT NULLUniquely identifies a version of a Contract of a particular origin for a particular owner.
MEMBER_IDBIGINT NOT NULLOwner of the Contract.
ORIGININTEGER NOT NULL DEFAULT 0Indicates why the Contract was created: 0 = manual 1 = imported 2 = RFQ 3 = exchange 4 = auction 5 = 2-party negotiation 6 = deployment
STATEINTEGER NOT NULL DEFAULT 0Indicates the contract state: 0 = draft 1 = pending approval 2 = approved 3 = active 4 = rejected 5 = canceled 6 = closed 7 = suspended -1 = deployment in progress -2 = deployment failed
USAGEINTEGER NOT NULL DEFAULT 0Indicates how the contract will be used: 0 = default 1 = organization buyer 2 = reseller 3 = special bid 4 = referral 5 = supplier 6 = delegation grid
MARKFORDELETEINTEGER NOT NULL DEFAULT 0Indicates if this Contract has been marked for deletion: 0 = No 1 = Yes and this Contract has been marked for deletion
COMMENTSVARCHAR (4000)A comment associated with the Contract.
TIMECREATEDTIMESTAMPThe time the Contract was created.
TIMEUPDATEDTIMESTAMPThe time the Contract was most recently updated.
TIMEAPPROVEDTIMESTAMPThe time the Contract was approved.
TIMEACTIVATEDTIMESTAMPThe time the Contract was activated.
TIMEDEPLOYEDTIMESTAMPThe time the Contract was deployed.
FAMILY_IDBIGINTThe contract belongs to this family of contracts with the same name, owner, and origin.
OPTCOUNTERSMALLINT NOT NULL DEFAULT 0The optimistic concurrency control counter for the table. Every time there is an update to the table, the counter is incremented.

Indexes:

NameColumn NamesType
<SYSTEM-GENERATED>CONTRACT_IDPrimary Key
I0000078 NAME+MEMBER_ID+MAJORVERSION+MINORVERSION+ORIGINUnique Index
I0000539MEMBER_IDNon-Unique Index
I0001510FAMILY_IDNon-Unique Index

Constrained By Parent Tables:

ConstraintColumnsParent TableParent ColumnsType
F_252CONTRACT_IDTRADINGTRADING_IDCascade
F_253MEMBER_IDMEMBERMEMBER_IDCascade

Referenced By Child Tables:

ConstraintColumnsChild TableChild ColumnsType
F_139CONTRACT_IDBUYSUPMAPCONTRACT_IDCascade
F_188CONTRACT_IDCATCNTRCONTRACT_IDCascade
F_246CONTRACT_IDCNTRDISPLYCONTRACT_IDCascade
F_785CONTRACT_IDSTORECNTRCONTRACT_IDCascade
F_788CONTRACT_IDSTOREDEFCONTRACT_IDCascade
F_833CONTRACT_IDTDPSCNCNTRCONTRACT_IDCascade
F_912CONTRACT_IDCNTRSTORECONTRACT_IDCascade
F_925CONTRACT_IDSTORECRTDBYCNTR_IDCascade