# OrderItems Lists order items that match specified search criteria. This call returns an array of objects, but detailed information about each object’s attributes might not be included. See https://developer.adobe.com/commerce/webapi/rest/attributes#OrderItemRepositoryInterface to determine which call to use to get detailed information about all attributes for an object. ## Documentation Lists order items that match specified search criteria. This call returns an array of objects, but detailed information about each object’s attributes might not be included. See https://developer.adobe.com/commerce/webapi/rest/attributes#OrderItemRepositoryInterface to determine which call to use to get detailed information about all attributes for an object. - Catalog: `Magento` - Schema: `Sales` - Primary Keys: `item_id` This is a read-only table function. The Magento API may not support changing the data or the Invantive UniversalSQL driver for Magento does not cover it. In the latter case, please use the table NativePlatformScalarRequests to upload data to the Magento API. ## Parameters of Table Function The following parameters can be used to control the behaviour of the table function `OrderItems`. A value must be provided at all times for required parameters, but optional parameters in general do not need to have a value and the execution will default to a pre-defined behaviour. Values can be specified by position and by name. In both cases, all parameters not specified will be evaluated using their default values. Value specification by position is done by listing all values from the first to the last needed value. For example: a `select * from table(value1, value2, value3)` on a table with four parameters will use the default value for the fourth parameter and the specified values for the first three. Value specification by name is done by listing all values that require a value. For example with `select * from table(name1 => value1, name3 => value3)` on the same table will use the default values for the second and fourth parameters and the specified values for the first and third. | Name | Data Type | Required | Default Value | Documentation | |---|:---:|:---:|:---:|---| | `searchCriteria[currentPage]` | `` | ☐ | | Current page. | | `searchCriteria[filterGroups][0][filters][0][conditionType]` | `` | ☐ | | Condition type | | `searchCriteria[filterGroups][0][filters][0][field]` | `` | ☐ | | Field | | `searchCriteria[filterGroups][0][filters][0][value]` | `` | ☐ | | Value | | `searchCriteria[pageSize]` | `` | ☐ | | Page size. | | `searchCriteria[sortOrders][0][direction]` | `` | ☐ | | Sorting direction. | | `searchCriteria[sortOrders][0][field]` | `` | ☐ | | Sorting field. | ## Columns of Table Function The columns of the table function `OrderItems` are shown below. Each column has an SQL data type. | Name | Data Type | Label | Required | Documentation | |---|:---:|---|:---:|---| | `additional_data` | `varchar2` | | ☐ | Additional data. | | `amount_refunded` | `decimal` | | ☐ | Amount refunded. | | `applied_rule_ids` | `varchar2` | | ☐ | Applied rule IDs. | | `base_amount_refunded` | `decimal` | | ☐ | Base amount refunded. | | `base_cost` | `decimal` | | ☐ | Base cost. | | `base_discount_amount` | `decimal` | | ☐ | Base discount amount. | | `base_discount_invoiced` | `decimal` | | ☐ | Base discount invoiced. | | `base_discount_refunded` | `decimal` | | ☐ | Base discount refunded. | | `base_discount_tax_compensation_amount` | `decimal` | | ☐ | Base discount tax compensation amount. | | `base_discount_tax_compensation_invoiced` | `decimal` | | ☐ | Base discount tax compensation invoiced. | | `base_discount_tax_compensation_refunded` | `decimal` | | ☐ | Base discount tax compensation refunded. | | `base_original_price` | `decimal` | | ☐ | Base original price. | | `base_price_incl_tax` | `decimal` | | ☐ | Base price including tax. | | `base_price` | `decimal` | | ☐ | Base price. | | `base_row_invoiced` | `decimal` | | ☐ | Base row invoiced. | | `base_row_total_incl_tax` | `decimal` | | ☐ | Base row total including tax. | | `base_row_total` | `decimal` | | ☐ | Base row total. | | `base_tax_amount` | `decimal` | | ☐ | Base tax amount. | | `base_tax_before_discount` | `decimal` | | ☐ | Base tax before discount. | | `base_tax_invoiced` | `decimal` | | ☐ | Base tax invoiced. | | `base_tax_refunded` | `decimal` | | ☐ | Base tax refunded. | | `base_weee_tax_applied_amount` | `decimal` | | ☐ | Base WEEE tax applied amount. | | `base_weee_tax_applied_row_amnt` | `decimal` | | ☐ | Base WEEE tax applied row amount. | | `base_weee_tax_disposition` | `decimal` | | ☐ | Base WEEE tax disposition. | | `base_weee_tax_row_disposition` | `decimal` | | ☐ | Base WEEE tax row disposition. | | `created_at` | `varchar2` | | ☐ | Created-at timestamp. | | `description` | `varchar2` | | ☐ | Description. | | `discount_amount` | `decimal` | | ☐ | Discount amount. | | `discount_invoiced` | `decimal` | | ☐ | Discount invoiced. | | `discount_percent` | `decimal` | | ☐ | Discount percent. | | `discount_refunded` | `decimal` | | ☐ | Discount refunded. | | `discount_tax_compensation_amount` | `decimal` | | ☐ | Discount tax compensation amount. | | `discount_tax_compensation_canceled` | `decimal` | | ☐ | Discount tax compensation canceled. | | `discount_tax_compensation_invoiced` | `decimal` | | ☐ | Discount tax compensation invoiced. | | `discount_tax_compensation_refunded` | `decimal` | | ☐ | Discount tax compensation refunded. | | `event_id` | `int64` | | ☐ | Event ID. | | `ext_order_item_id` | `varchar2` | | ☐ | External order item ID. | | `extension_attributes_gift_message_customer_id` | `int64` | | ☐ | Customer ID. Otherwise, null. | | `extension_attributes_gift_message_extension_attributes_entity_id` | `varchar2` | | ☐ | | | `extension_attributes_gift_message_extension_attributes_entity_type` | `varchar2` | | ☐ | | | `extension_attributes_gift_message_gift_message_id` | `int64` | | ☐ | Gift message ID. Otherwise, null. | | `extension_attributes_gift_message_message` | `varchar2` | | ☐ | Message text. | | `extension_attributes_gift_message_recipient` | `varchar2` | | ☐ | Recipient name. | | `extension_attributes_gift_message_sender` | `varchar2` | | ☐ | Sender name. | | `free_shipping` | `int64` | | ☐ | Free-shipping flag value. | | `gw_base_price_invoiced` | `decimal` | | ☐ | GW base price invoiced. | | `gw_base_price_refunded` | `decimal` | | ☐ | GW base price refunded. | | `gw_base_price` | `decimal` | | ☐ | GW base price. | | `gw_base_tax_amount_invoiced` | `decimal` | | ☐ | GW base tax amount invoiced. | | `gw_base_tax_amount_refunded` | `decimal` | | ☐ | GW base tax amount refunded. | | `gw_base_tax_amount` | `decimal` | | ☐ | GW base tax amount. | | `gw_id` | `int64` | | ☐ | GW ID. | | `gw_price_invoiced` | `decimal` | | ☐ | GW price invoiced. | | `gw_price_refunded` | `decimal` | | ☐ | GW price refunded. | | `gw_price` | `decimal` | | ☐ | GW price. | | `gw_tax_amount_invoiced` | `decimal` | | ☐ | GW tax amount invoiced. | | `gw_tax_amount_refunded` | `decimal` | | ☐ | GW tax amount refunded. | | `gw_tax_amount` | `decimal` | | ☐ | GW tax amount. | | `is_qty_decimal` | `int64` | | ☐ | Is-quantity-decimal flag value. | | `is_virtual` | `int64` | | ☐ | Is-virtual flag value. | | `item_id` | `int64` | | ☐ | Item ID. | | `locked_do_invoice` | `int64` | | ☐ | Locked DO invoice flag value. | | `locked_do_ship` | `int64` | | ☐ | Locked DO ship flag value. | | `name` | `varchar2` | | ☐ | Name. | | `no_discount` | `int64` | | ☐ | No-discount flag value. | | `order_id` | `int64` | | ☐ | Order ID. | | `original_price` | `decimal` | | ☐ | Original price. | | `parent_item_id` | `int64` | | ☐ | Parent item ID. | | `price_incl_tax` | `decimal` | | ☐ | Price including tax. | | `price` | `decimal` | | ☐ | Price. | | `product_id` | `int64` | | ☐ | Product ID. | | `product_option_extension_attributes_downloadable_option_downloadable_links` | `varchar2` | | ☐ | The list of downloadable links | | `product_type` | `varchar2` | | ☐ | Product type. | | `qty_backordered` | `decimal` | | ☐ | Quantity backordered. | | `qty_canceled` | `decimal` | | ☐ | Quantity canceled. | | `qty_invoiced` | `decimal` | | ☐ | Quantity invoiced. | | `qty_ordered` | `decimal` | | ☐ | Quantity ordered. | | `qty_refunded` | `decimal` | | ☐ | Quantity refunded. | | `qty_returned` | `decimal` | | ☐ | Quantity returned. | | `qty_shipped` | `decimal` | | ☐ | Quantity shipped. | | `quote_item_id` | `int64` | | ☐ | Quote item ID. | | `row_invoiced` | `decimal` | | ☐ | Row invoiced. | | `row_total_incl_tax` | `decimal` | | ☐ | Row total including tax. | | `row_total` | `decimal` | | ☐ | Row total. | | `row_weight` | `decimal` | | ☐ | Row weight. | | `sku` | `varchar2` | | ☐ | SKU. | | `store_id` | `int64` | | ☐ | Store ID. | | `tax_amount` | `decimal` | | ☐ | Tax amount. | | `tax_before_discount` | `decimal` | | ☐ | Tax before discount. | | `tax_canceled` | `decimal` | | ☐ | Tax canceled. | | `tax_invoiced` | `decimal` | | ☐ | Tax invoiced. | | `tax_percent` | `decimal` | | ☐ | Tax percent. | | `tax_refunded` | `decimal` | | ☐ | Tax refunded. | | `updated_at` | `varchar2` | | ☐ | Updated-at timestamp. | | `weee_tax_applied_amount` | `decimal` | | ☐ | WEEE tax applied amount. | | `weee_tax_applied_row_amount` | `decimal` | | ☐ | WEEE tax applied row amount. | | `weee_tax_applied` | `varchar2` | | ☐ | WEEE tax applied. | | `weee_tax_disposition` | `decimal` | | ☐ | WEEE tax disposition. | | `weee_tax_row_disposition` | `decimal` | | ☐ | WEEE tax row disposition. | | `weight` | `decimal` | | ☐ | Weight. |