Table: dbo.AR_Transaction_Template_Item
Tracks items associated with an AR template.
Columns
NameTypeConstraintsDescription
ar_transaction_template_item_KEYint (4)NOT NULLA primary key.
ar_item_KEYint (4)NOT NULLLinks to the associated AR item. This table will share all the data with the AR item it is linked to. When an entry in the AR item table is deleted, all the associated entries in the template table must be deleted as well.
transaction_template_KEYint (4)NOT NULLLinks back to its parent AR transaction template.
quantitydecimal (9, 4)NOT NULLWhen generating an AR transaction item from this template item, this will fill in the quantity of the item to use.
sequence_numberint (4)NOT NULLThe sequence number for this template item. When generating an AR transaction item from this template item, this will be the assigned sequence number.
amount_overridedecimal (9, 2)An override for the amount on the template item. If not null, this value should be used instead of the amount on the corresponding AR item. If null, the relevant amount field on the AR item should be used.
per_item_price_overridedecimal (9, 4)An override for the per item price on the template item. If not null, this value should be used instead of the per item price on the corresponding AR item. If null, the per item price field on the AR item should be used.
description_overridenvarchar (2000)An override for the description on this template item. If null, the description for the template item will be pulled from the linked AR item row.
Primary key
NameColumnsDescription
PK_AR_Transaction_Template_Itemar_transaction_template_item_KEY
Foreign keys
NameColumnsReferenced tableDescription
FK_AR_Transaction_Template_Item__AR_Item__ar_item_KEYar_item_KEYAR_Item (ar_item_KEY)
FK_AR_Transaction_Template_Item__AR_Transaction_Template__transaction_template_KEYtransaction_template_KEYAR_Transaction_Template (transaction_template_KEY)

Schema diagram