Table: Billing_Decision_Taxing_Authority
Columns
NameTypeConstraintsDescription
billing_decision_taxing_authority_KEYintNOT NULLAUTO-INCREMENT: DEPRECATED. Database assigned primary key for this table.
update__staff_KEYintNOT NULL
update_date_utcdatetimeNOT NULL
create_date_utcdatetimeNOT NULL
billing_decision_KEYintNOT NULLDEPRECATED. Identifies the Billing_Decision row this tax is charged for.
sheet_entry_KEYintNOT NULLThe combination of ledger_entry_KEY and sheet_entry_KEY identifies the Billing_Decision row this tax is charged for.
ledger_entry_KEYintNOT NULLThe combination of ledger_entry_KEY and sheet_entry_KEY identifies the Billing_Decision row this tax is charged for.
taxing_authority_KEYintNOT NULLKey to the Taxing Authority that this tax is charged for.
amountdecimal (9, 2)NOT NULLThe amount of tax charged.
calculated_amountdecimal (9, 2)NOT NULLCalculated amount of tax charged.
amount_is_overriddenbitNOT NULLTrue when the calculated_amount is overridden and is necessary so that the override is not deleted if the values happen to match later.
Primary key
NameColumnsDescription
PK_Billing_Decision_Taxing_Authority$sheet_entry_KEY$ledger_entry_KEY$taxing_authority_KEYsheet_entry_KEY, ledger_entry_KEY, taxing_authority_KEYCLUSTERED
Unique constraints
NameColumnsDescription
UK_Billing_Decision_Taxing_Authority$billing_decision_taxing_authority_KEYbilling_decision_taxing_authority_KEY
Indexes
NameColumnsDescription
IX_Billing_Decision_Taxing_Authority$billing_decision_KEY$amountbilling_decision_KEY, amount
IX_Billing_Decision_Taxing_Authority$ledger_entry_KEY$amountledger_entry_KEY, amount
IX_Billing_Decision_Taxing_Authority$taxing_authority_KEY$amounttaxing_authority_KEY, amount
Foreign keys
NameColumnsReferenced tableDescription
FK_Billing_Decision_Taxing_Authority__Billing_Decision__billing_decision_KEYbilling_decision_KEYBilling_Decision
FK_Billing_Decision_Taxing_Authority__Billing_Decision__sheet_entry_KEY__ledger_entry_KEYsheet_entry_KEY, ledger_entry_KEYBilling_Decision
FK_Billing_Decision_Taxing_Authority__Taxing_Authority__taxing_authority_KEYtaxing_authority_KEYTaxing_Authority
Incoming foreign keys
NameColumnsReferencing tableDescription
FK_Billing_Decision_Tax_Collection__Billing_Decision_Taxing_Authority__sheet_entry_KEY__ledger_entry_KEY__taxing_authority_KEYsheet_entry_KEY, ledger_entry_KEY, taxing_authority_KEYBilling_Decision_Tax_Collectionon delete cascade;

Schema diagram