Table: dbo.AR_Transaction_Template
Contains templates that can be used to generate an AR transaction.
Columns
Name | Type | Constraints | Description
transaction_template_KEY | int (4) | NOT NULL | Specifies what type of AR transaction this template will be used to generate. It will either be an invoice or a credit memo.
ar_transaction_type_KEY | int (4) | NOT NULL |
reference_number | nvarchar (32) | NOT NULL | The reference number a generated transaction will be assigned. Every transaction generated by this template will be given this same reference number.
purchase_order_number | nvarchar (32) | NOT NULL | The purchase order number a generated transaction will be assigned. Every transaction generated by this template will be given this same purchase order number.
payment_discount_amount | decimal (9, 2) | NOT NULL | If there is a discount for the generated transaction, this is the amount that will be used instead of the normal amount.
payment_term_KEY | int (4) |  | The payment term a generated transaction will be assigned. A null value indicates that no payment term is specified for the template and so the payment term will not be filled in when users create transactions from the template.
gl_account_KEY | int (4) | NOT NULL | The GL account that will be associated with this template. This account will be associated with all transactions generated by this template.
payment_discount__gl_account_KEY | int (4) |  | The GL account that will be associated with the discount amount for this template. A null value indicates that no GL account is specified for a generated transaction to use for discounts.
shipping__contact_address_type_KEY | int (4) |  | Specifies which address type to use for shipping on a generated transaction. A null value indicates that no contact address type is specified; this is typical of templates that do not involve shipping items.
shipping_salutation | nvarchar (80) | NOT NULL | Specifies the salutation that will be used for the shipping name on a transaction generated from this template.
shipping_name | nvarchar (100) | NOT NULL | Specifies the name that will be used for shipping on a transaction generated from this template.
create_as_printed | bit (1) | NOT NULL | Specifies whether to mark transactions that are generated from this template as printed transactions when they are created.
message | nvarchar (2000) | NOT NULL | The message a generated transaction will be assigned. Every transaction generated by this template will be given this same message.

Primary key
Name | Columns | Description
PK_AR_Transaction_Template$transaction_template_KEY | transaction_template_KEY |

Foreign keys
Name | Columns | Referenced table | Description
FK_AR_Transaction_Template__AR_Transaction_Type__ar_transaction_type_KEY | ar_transaction_type_KEY | AR_Transaction_Type (ar_transaction_type_KEY) |
FK_AR_Transaction_Template__Contact_Address_Type__shipping__contact_address_type_KEY | shipping__contact_address_type_KEY | Contact_Address_Type (contact_address_type_KEY) |
FK_AR_Transaction_Template__GL_Account__gl_account_KEY | gl_account_KEY | GL_Account (gl_account_KEY) |
FK_AR_Transaction_Template__GL_Account__payment_discount__gl_account_KEY | payment_discount__gl_account_KEY | GL_Account (gl_account_KEY) |
FK_AR_Transaction_Template__Payment_Term__payment_term_KEY | payment_term_KEY | Payment_Term (payment_term_KEY) |
FK_AR_Transaction_Template__Transaction_Template__transaction_template_KEY | transaction_template_KEY | Transaction_Template (transaction_template_KEY) |

Incoming foreign keys
Name | Columns | Referencing table | Description
FK_AR_Transaction_Template_Item__AR_Transaction_Template__transaction_template_KEY | transaction_template_KEY | AR_Transaction_Template_Item |
FK_AR_Transaction_Template_N_Customer__AR_Transaction_Template__transaction_template_KEY | transaction_template_KEY | AR_Transaction_Template_N_Customer |
FK_AR_Transaction__AR_Transaction_Template__generated_by__transaction_template_KEY | generated_by__transaction_template_KEY | AR_Transaction |