Columns
| Column | Type | Size | Nulls | Auto | Default | Children | Parents | Comments | ||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| ACTIVE_HUB_KEY | int identity | 4 | √ | null |
|
|
The Hub record ID |
|||||||
| COUPON_BATCH_ID | int | 4 | √ | null |
|
|
Coupon batch ID |
|||||||
| COUPON_BATCH_TITLE | varchar | 100 | √ | null |
|
|
Coupon batch title |
|||||||
| COUPON_CODE_PREFIX | varchar | 5 | √ | null |
|
|
Coupon code prefix to be used when generating coupons |
|||||||
| COUPON_CODE_SUFFIX | varchar | 5 | √ | null |
|
|
Coupon code suffix to be used when generating coupons |
|||||||
| COUPON_CODE_MIN_NUMBER | int | 4 | √ | null |
|
|
Coupon code starting number to be used when generating coupons |
|||||||
| COUPON_CODE_MAX_NUMBER | int | 4 | √ | null |
|
|
Coupon code ending number to be used when generating coupons |
|||||||
| COUPON_TITLE | varchar | 100 | √ | null |
|
|
Coupon title for generated coupons |
|||||||
| COUPON_TYPE | varchar | 30 | √ | null |
|
|
Coupon type for generated coupons |
|||||||
| DISCOUNT_TYPE | varchar | 10 | √ | null |
|
|
Discount type (amount / discount) |
|||||||
| CHARGE_ID | int | 4 | √ | null |
|
|
Charge ID to be associated to the coupons |
|||||||
| COUPON_CATEGORY_ID | int | 4 | √ | null |
|
|
Coupon category ID |
|||||||
| DISCOUNT_AMOUNT | money | 21,4 | √ | null |
|
|
Coupon discount amount |
|||||||
| DISCOUNT_PERCENT | money | 21,4 | √ | null |
|
|
Coupon discount percentage |
|||||||
| GLACCOUNT_ID | int | 4 | √ | null |
|
|
Coupon GL account ID |
|||||||
| DATE_FROM | date | 20 | √ | null |
|
|
Coupon effective date from |
|||||||
| DATE_TO | date | 20 | √ | null |
|
|
Coupon effective date to |
|||||||
| FREQUENCY_NUMBER | int | 4 | √ | null |
|
|
Coupon may be used again after this many days, weeks or months |
|||||||
| FREQUENCY_PERIOD | varchar | 10 | √ | null |
|
|
Period for coupon reuse (Days / Weeks / Months) |
|||||||
| DAYS_OF_WEEK | varchar | 7 | √ | null |
|
|
Whether the coupons will be configured for use on specific days of the week |
|||||||
| WEEKS_OF_MONTH | varchar | 5 | √ | null |
|
|
Whether the coupons will be configured for use on specific weeks of the month |
|||||||
| MONTHS_OF_YEAR | varchar | 12 | √ | null |
|
|
Whether the coupons will be configured for use on specific months of the year |
|||||||
| MAX_NUMBER_OF_USES | int | 4 | √ | null |
|
|
The total number of times that each coupon may be used |
|||||||
| CUSTOMER_LIST_ID | int | 4 | √ | null |
|
|
The ID of the custom list identifying the customers to be assigned coupons |
|||||||
| NUMBER_PER_CUSTOMER | int | 4 | √ | null |
|
|
Number of coupons to be assigned to each customer |
|||||||
| MAX_NUMBER_OF_USES_PER_CUSTOMER | int | 4 | √ | null |
|
|
Maximum uses per customer for each coupon |
|||||||
| NOTIFY_CUSTOMER | varchar | 5 | √ | null |
|
|
Whether a notification should be emailed to each customer who gets coupons assigned to them (Yes/No) |
|||||||
| ROW_VERSION | binary | 8 | √ | null |
|
|
System timestamp (for internal use) |
|||||||
| LAST_SYNC_TIME | datetime | 16,3 | (getdate()) |
|
|
Date and time Hub record was last modified |
||||||||
| ACTIVE_HUB_PROCESS_ID | bigint | 8 | √ | null |
|
|
The Hub sync process ID |
|||||||
| ORG_ID | int | 4 | √ | null |
|
|
Your organization’s unique identifier in the Active Net system |
|||||||
| COUPON_DESCRIPTION | varchar | 8000 | √ | null |
|
|
Coupon description of generated coupons |
Indexes
| Constraint Name | Type | Sort | Column(s) |
|---|---|---|---|
| COUPON_BATCHES_ACTIVE_HUB_KEY_PK | Primary key | Asc | ACTIVE_HUB_KEY |
| COUPON_BATCHES_CHARGE_ID_IX | Performance | Asc | CHARGE_ID |
| COUPON_BATCHES_COUPON_BATCH_ID_ORG_ID_UQ | Must be unique | Asc/Asc | COUPON_BATCH_ID + ORG_ID |
| COUPON_BATCHES_COUPON_CATEGORY_ID_IX | Performance | Asc | COUPON_CATEGORY_ID |
| COUPON_BATCHES_CUSTOMER_LIST_ID_IX | Performance | Asc | CUSTOMER_LIST_ID |
| COUPON_BATCHES_GLACCOUNT_ID_IX | Performance | Asc | GLACCOUNT_ID |
| COUPON_BATCHES_ROW_VERSION_IX | Performance | Asc | ROW_VERSION |