CreditMemoLineItems
Manages individual line items within QuickBooks Credit Memos, allowing creation, updates, deletion, and detailed queries.
Table Specific Information
CreditMemos may be inserted, queried, or updated via the CreditMemoLineItems table. CreditMemos may be deleted by using the CreditMemos table.
This table has a Custom Fields column. See the Custom Fields page for more information.
Select
By default, SupportEnhancedSQL is set to true, and the following will be honored if present. Other filters will be executed client side. If SupportEnhancedSQL is set to false, only the following filters will be honored.
QuickBooks allows only a small subset of columns to be used in the WHERE clause of a SELECT query. These columns can typically be used with only the equals or = comparison. The available columns for CreditMemos are Id, ReferenceNumber, Date, TimeModified, CustomerName, CustomerId, AccountsReceivable, and AccountsReceivableId. TimeModified and Date may be used with the >, >=, <, <=, or = conditions and may be used twice to specify a range. ReferenceNumber may be used with the = or LIKE conditions to establish a starts-with, ends-with, or contains syntax. For example:
SELECT * FROM CreditMemoLineItems WHERE TimeModified > '1/1/2011' AND TimeModified < '2/1/2011' AND ReferenceNumber LIKE '%12345%'
Insert
To add a CreditMemo, specify a Customer and at least one Line Item. All Line Item columns can be used for inserting multiple Line Items for a new CreditMemo transaction. For example, the following will insert a new CreditMemo with two Line Items:
INSERT INTO CreditMemoLineItems#TEMP (CustomerName, ItemName, ItemQuantity) VALUES ('Abercrombie, Kristy', 'Repairs', 1) INSERT INTO CreditMemoLineItems#TEMP (CustomerName, ItemName, ItemQuantity) VALUES ('Abercrombie, Kristy', 'Removal', 2) INSERT INTO CreditMemoLineItems (CustomerName, ItemName, ItemQuantity) SELECT CustomerName, ItemName, ItemQuantity FROM CreditMemoLineItems#TEMP
Columns
Name | Type | ReadOnly | References | ColumnSize | Description |
ID [KEY] | String | True | 255 |
The unique identifier for the credit memo line item, formatted as CreditMemoId|ItemLineId. | |
CreditMemoId | String | False |
CreditMemos.ID | 255 |
The unique identifier of the credit memo associated with this line item. |
ReferenceNumber | String | False | 21 |
The reference number for the credit memo transaction. | |
TxnNumber | Integer | True |
A manually assigned transaction number to identify the credit memo separately from the Quickbooks generated ID. | ||
Date | Date | False |
The date of the credit memo transaction. If specified in the WHERE clause of a SELECT query, it overrides the pseudo columns StartDate and EndDate. | ||
CustomerName | String | False | 1000 |
The name of the customer on the credit memo. Either CustomerName or CustomerId must be provided when inserting. | |
CustomerId | String | False |
Customers.ID | 255 |
The unique identifier of the customer on the credit memo. Either CustomerName or CustomerId must be provided when inserting. |
AccountsReceivable | String | False | 1000 |
The name of the accounts-receivable account where the transaction is recorded. | |
AccountsReceivableId | String | False |
Accounts.ID | 255 |
The unique identifier of the accounts-receivable account where the transaction is recorded. |
ShipMethod | String | False | 1000 |
The method used for shipping associated with this credit memo. | |
ShipMethodId | String | False | 255 |
The unique identifier for the shipping method. | |
ShipDate | Date | False |
The date when the items were shipped. | ||
Memo | String | False | 5000 |
A memo providing additional information about this credit memo transaction. | |
Amount | Decimal | False |
The total amount for this transaction. | ||
Message | String | False | 101 |
A message to be communicated to the customer. | |
MessageId | String | False | 255 |
The unique identifier for the message to the customer. | |
SalesRep | String | False | 5 |
The initials or reference to the sales representative associated with this transaction. | |
SalesRepId | String | False |
SalesReps.ID | 255 |
The unique identifier for the sales representative. |
FOB | String | False | 13 |
The place where the ownership of goods transfers (Freight on Board). | |
BillingAddress | String | True |
The full billing address for this credit memo. | ||
BillingLine1 | String | False | 500 |
The first line of the billing address. | |
BillingLine2 | String | False | 500 |
The second line of the billing address. | |
BillingLine3 | String | False | 500 |
The third line of the billing address. | |
BillingLine4 | String | False | 500 |
The fourth line of the billing address. | |
BillingLine5 | String | False | 41 |
The fifth line of the billing address. | |
BillingCity | String | False | 255 |
The city associated with the billing address. | |
BillingState | String | False | 255 |
The state associated with the billing address. | |
BillingPostalCode | String | False | 30 |
The postal code associated with the billing address. | |
BillingCountry | String | False | 255 |
The country associated with the billing address. | |
BillingNote | String | False | 41 |
A note associated with the billing address. | |
ShippingAddress | String | True |
The full shipping address for this credit memo. | ||
ShippingLine1 | String | False | 500 |
The first line of the shipping address. | |
ShippingLine2 | String | False | 500 |
The second line of the shipping address. | |
ShippingLine3 | String | False | 500 |
The third line of the shipping address. | |
ShippingLine4 | String | False | 500 |
The fourth line of the shipping address. | |
ShippingLine5 | String | False | 41 |
The fifth line of the shipping address. | |
ShippingCity | String | False | 255 |
The city associated with the shipping address. | |
ShippingState | String | False | 255 |
The state associated with the shipping address. | |
ShippingPostalCode | String | False | 30 |
The postal code associated with the shipping address. | |
ShippingCountry | String | False | 255 |
The country associated with the shipping address. | |
ShippingNote | String | False | 41 |
A note associated with the shipping address. | |
Subtotal | Decimal | True |
The gross subtotal for this transaction, excluding tax or previously paid amounts. | ||
Tax | Double | False |
The total sales tax applied to this transaction. | ||
TaxItem | String | False | 100 |
The name of the sales tax item applied to this transaction. | |
TaxItemId | String | False | 255 |
The unique identifier of the sales tax item applied to this transaction. | |
TaxPercent | Double | True |
The percentage rate charged for sales tax. | ||
IsPending | Boolean | False |
Indicates whether the transaction is pending or completed. | ||
IsToBeEmailed | Boolean | False |
Indicates whether this credit memo is to be emailed to the customer. | ||
IsToBePrinted | Boolean | False |
Indicates whether this credit memo is to be printed. | ||
IsTaxIncluded | Boolean | False |
Determines if tax is included in the transaction amount. Available only in international editions of QuickBooks. | ||
PONumber | String | False | 25 |
The purchase order number associated with this transaction. | |
Terms | String | False | 100 |
The payment terms for the transaction. | |
TermsId | String | False | 255 |
The unique identifier for the payment terms. | |
CreditRemaining | Double | True |
The remaining credit amount available on this transaction. | ||
DueDate | Date | False |
The date when the credit is due. | ||
Template | String | False | 100 |
The name of the template applied to this transaction. | |
TemplateId | String | False |
Templates.ID | 255 |
The unique identifier of the template applied to this transaction. |
CustomerSalesTax | String | False | 3 |
The sales tax information associated with the customer. | |
CustomerSalesTaxId | String | False | 255 |
The unique identifier of the sales tax information for the customer. | |
Class | String | False | 1000 |
The class associated with the transaction for categorization. | |
ClassId | String | False |
Class.ID | 255 |
The unique identifier of the class associated with this transaction. |
ExchangeRate | Double | False |
The exchange rate used for this transaction's currency conversion. | ||
CustomFields | String | False |
Custom fields returned from QuickBooks, formatted as XML. | ||
ItemLineId | String | True | 255 |
The unique identifier for the line item. | |
ItemLineNumber | String | True | 255 |
The line number for this item within the credit memo. | |
ItemName | String | False |
The name of the item associated with this line. | ||
ItemId | String | False |
Items.ID | 255 |
The unique identifier of the item associated with this line. |
ItemGroup | String | False | 100 |
The name of the group this item belongs to, if applicable. | |
ItemGroupId | String | False |
Items.ID | 255 |
The unique identifier of the group this item belongs to, if applicable. |
ItemDescription | String | False | 5000 |
A detailed description of the item listed in this line. | |
ItemUnitOfMeasure | String | False | 31 |
The unit of measure for the item. Requires QBXML Version 7.0 or higher. | |
ItemQuantity | Double | False |
The quantity of the item specified in this line. | ||
ItemRate | Double | False |
The rate charged per unit for this item. | ||
ItemRatePercent | Double | False |
The rate percentage charged for this item, if applicable. | ||
ItemTaxCode | String | False | 3 |
The sales tax code for this item, indicating taxable or nontaxable status. | |
ItemTaxCodeId | String | False | 255 |
The unique identifier of the sales tax code for this item. | |
ItemAmount | Decimal | False |
The total amount for this item line. | ||
ItemClass | String | False | 1000 |
The class associated with this item. | |
ItemClassId | String | False |
Class.ID | 255 |
The unique identifier for the class of this item. |
ItemInventorySiteName | String | False | 31 |
The name of the inventory site for this item. Requires QBXML Version 10.0 or higher. | |
ItemInventorySiteId | String | False | 255 |
The unique identifier of the inventory site for this item. Requires QBXML Version 10.0 or higher. | |
ItemInventorySiteLocationName | String | False | 31 |
The name of the inventory site location for this item. Requires QBXML Version 10.0 or higher. | |
ItemInventorySiteLocationId | String | False | 255 |
The unique identifier of the inventory site location for this item. Requires QBXML Version 10.0 or higher. | |
ItemSerialNumber | String | False | 5000 |
The serial number associated with this item. Requires QBXML Version 11.0 or higher. | |
ItemLotNumber | String | False | 40 |
The lot number associated with this item. Requires QBXML Version 11.0 or higher. | |
ItemExpirationDateForSerialLotNumber | String | True | 1099 |
The expiration date for the serial or lot number of this item. Requires QBXML Version 16.0 or higher. | |
ItemOther1 | String | False | 29 |
The custom field 'Other1' associated with this line item. Requires QBXML Version 6.0 or higher. | |
ItemOther2 | String | False | 29 |
The custom field 'Other2' associated with this line item. Requires QBXML Version 6.0 or higher. | |
ItemCustomFields | String | False |
Custom fields associated with this line item. | ||
ItemUOMSetFullName | String | False | 1000 |
The full name of the unit of measure set for this item. | |
ItemUOMSetListID | String | False | 1000 |
The unique identifier of the unit of measure set for this item. | |
ItemIsGetPrintItemsInGroup | String | False | 1000 |
Indicates whether a list of this group's individual items and their amounts appear on printed forms. | |
EditSequence | String | True | 16 |
An identifier used for versioning this transaction object. | |
TimeModified | Datetime | True |
The timestamp of the last modification made to this credit memo. | ||
TimeCreated | Datetime | True |
The timestamp of when this credit memo was originally created. |
Pseudo-Columns
Pseudo Column fields are used in the WHERE clause of SELECT statements and offer a more granular control over the tuples that are returned from the data source.
Name | Type | Description |
ItemPriceLevel | String |
The price level associated with the item. QuickBooks does not return the price level. |
ItemOverrideAccount | String |
The name of the account used to override the default account for this item. Available during inserts and updates. |
ItemOverrideAccountId | String |
The unique identifier of the account used to override the default account for this item. Available during inserts and updates. |