DiscountsAutomaticBxgy
Returns a list of discounts.
Table-Specific Information
Select
The driver uses the Shopify API to process WHERE clause conditions built with the following columns and operators. The driver processes other filters client-side within the driver.
- Title supports the '=, !=' comparison operators.
- Status supports the '=, !=' comparison operators.
- DiscountClass supports the '=, !=' comparison operators.
- StartsAt supports the '=, !=, <, >, >=, <=' comparison operators.
For example, the following queries are processed server-side:
SELECT * FROM DiscountsAutomaticBxgy WHERE Title = 'Val1'
SELECT * FROM DiscountsAutomaticBxgy WHERE Status = 'Val1'
SELECT * FROM DiscountsAutomaticBxgy WHERE DiscountClass = 'Val1'
SELECT * FROM DiscountsAutomaticBxgy WHERE StartsAt = '2023-01-01 11:10:00'
Insert
The following columns can be used to create a new record:
Title, EndsAt, StartsAt, UsesPerOrderLimit, CombinesWithOrderDiscounts, CombinesWithProductDiscounts, CombinesWithShippingDiscounts
The following pseudo-columns can be used to create a new record:
DiscountOnQuantity, DiscountPercentage, ProductsToAdd, ProductsToRemove, DiscountQuantityToBuy, DiscountAmountToBuy, ProductsBuysToAdd, ProductsBuysToRemove
Update
The following columns can be updated:
Title, EndsAt, StartsAt, UsesPerOrderLimit, CombinesWithOrderDiscounts, CombinesWithProductDiscounts, CombinesWithShippingDiscounts
The following pseudo-columns can be used to update a record:
DiscountOnQuantity, DiscountPercentage, ProductsToAdd, ProductsToRemove, DiscountQuantityToBuy, DiscountAmountToBuy, ProductsBuysToAdd, ProductsBuysToRemove
Delete
You can delete entries by specifying the following column:
Id
Columns
| Name | Type | ReadOnly | References | Description |
| Id [KEY] | String | True |
A globally-unique ID. | |
| Title | String | False |
The title of the discount. | |
| Status | String | True |
The status of the discount. | |
| Summary | String | True |
A detailed summary of the discount. | |
| DiscountClass | String | True |
The class of the discount for combining purposes. | |
| EndsAt | Datetime | False |
The date and time when the discount ends. For open-ended discounts, use 'null'. | |
| StartsAt | Datetime | False |
The date and time when the discount starts. | |
| AsyncUsageCount | Int | True |
The number of times the discount has been used. This value is updated asynchronously and can be different than the actual usage count. | |
| UsesPerOrderLimit | Int | False |
The maximum number of times that the discount can be applied to an order. | |
| CreatedAt | Datetime | True |
The date and time when the discount was created. | |
| CombinesWithOrderDiscounts | Bool | False |
Combines with order discounts. | |
| CombinesWithProductDiscounts | Bool | False |
Combines with product discounts. | |
| CombinesWithShippingDiscounts | Bool | False |
Combines with shipping discounts. |
Pseudo-Columns
Pseudo-columns are fields that can only be used in the types of statements under which they are explicitly listed. They are not standard columns but instead provide additional functionality for specific operations.
| Name | Type | Description |
| DiscountOnQuantity | String |
The value of the discount. |
| DiscountPercentage | Double |
The value of the discount. |
| ProductsToAdd | String |
A simple, comma-separated list of products IDs to add. |
| ProductsToRemove | String |
A simple, comma-separated list of products IDs to remove. |
| DiscountQuantityToBuy | String |
The quantity of prerequisite items. |
| DiscountAmountToBuy | String |
The value of the discount. |
| ProductsBuysToAdd | String |
A simple, comma-separated list of products IDs to add. |
| ProductsBuysToRemove | String |
A simple, comma-separated list of products IDs to remove. |