Column Descriptions
Column Name
| Column Type
| Description
|
PX_COUPON_ID
| BIGINT NOT NULL
| The primary key of a coupon. This is the coupon ID.
|
USERS_ID
| BIGINT
| Foreign key to the USERS table. The identified customer is the owner of this coupon, if the coupon is issued to a registered user.
|
STOREENT_ID
| INTEGER NOT NULL
| Foreign key to the STOREENT table. The store entity ID, plus the name, plus the version uniquely identify the promotion for which this coupon is issued.
|
VERSION
| INTEGER NOT NULL
| The version of the promotion for which this coupon is issued.
|
EFFECTIVE
| TIMESTAMP NOT NULL
| The date on which this coupon first becomes active.
|
EXPIRE
| TIMESTAMP NOT NULL
| The date when this coupon expires.
|
STATUS
| INTEGER NOT NULL DEFAULT 0
| The current status of this coupon:
0: active
1: cancelled
2: being used in an order but not finalized yet
3: expired
4: deleted
The default value is 0.
|
ORDERS_ID
| BIGINT
| Foreign key to the ORDERS table. If this coupon is being used in an order, or applied to an order and cancelled, this identifies the order.
|
GUESTID
| VARCHAR(64)
| This is the token by which this guest user will be recognized next time, if the coupon is issued to a guest user.
|
NAME
| VARCHAR(128) NOT NULL
| The name of the promotion for which this coupon is issued.
|
CODE
| VARCHAR(128)
| An optional code to identify this coupon.
|
OPTCOUNTER
| SMALLINT
| Reserved for IBM internal use.
|