OrderItems
The order items included in the order. Every order has at least one order item.
Table Specific Information
Select
The 本製品 uses the Square API to process search criteria that refer to the OrderId column, while other filters are processed client side within the 本製品. You can turn off the client-side execution of the query by setting SupportEnhancedSQL to false in which case any search criteria that refers to other columns will have an unfiltered response.
Retrieve all the OrderItems found in every order of your Square account. Only orders that have been successfully charged are included in the response.
SELECT * FROM OrderItems
You can retrieve all order items from an order by specifying the OrderId.
SELECT * FROM OrderItems WHERE OrderId='TzratjkPk9rhOuLYvSXeznmVvIx5PVlZpg72GfPQGBxckDeeWNBN8yqnf11qTrg3W3AelXC1kB'
You can also use the IN operator to specify multiple OrderIds in the WHERE clause.
SELECT * FROM OrderItems WHERE OrderId IN ('XKKB7LD30TpfNyW3e843ziklKh4vWEvweQyL5l4ESJLH3N2XXNBN8yqnf11qTrg3W3AelXC1kB','pxICohrEXPDtoUitiZhG1um5uhp5WI7CRMHknbuKpaj53PXfWNBN8yqnf11qTrg3W3AelXC1kB','6j8avtXB5fIaPZ9H12beiZP7sCSiqguGhHpwmECsEaENswJnWNBN8yqnf11qTrg3W3AelXC1kB')
Columns
Name | Type | Description |
OrderId [KEY] | String | The order's unique ID. |
OrderItemNumber [KEY] | Integer | The nth item of the order. |
LocationId | String | The Id of the location. |
Name | String | The name of the order item. |
Quantity | String | The quantity purchased, as a string representation of a number. |
Note | String | The note of the order item. |
CatalogObjectId | String | The CatalogItemVariation id applied to this order item. |
VariationName | String | The name of the variation applied to this order item. |
Taxes | String | The taxes applied to this order item. |
Discounts | String | The discounts applied to this order item. |
Modifiers | String | The CatalogModifiers applied to this order item. |
BasePriceMoneyAmount | Integer | The base price for a single unit of the order item. |
BasePriceMoneyCurrency | String | The currency of the base price for a single unit of the order item. |
GrossSalesMoneyAmount | Integer | The gross sales amount of money calculated as (item base price + modifiers price) * quantity. |
GrossSalesMoneyCurrency | String | The currency of the gross sales. |
TotalTaxMoney | Integer | The total tax amount of money to collect for the order item. |
TotalTaxMoneyCurrency | String | The currency of the total tax amount of money to collect for the order item. |
TotalDiscountMoneyAmount | Integer | The total discount amount of money to collect for the order item. |
TotalDiscountMoneyCurrency | String | The currency of the total discount amount of money to collect for the order item. |
TotalMoneyAmount | Integer | The total amount of money to collect for this order item. |
TotalMoneyCurrency | String | The currency of the total amount of money to collect for this order item. |