====== pears.AdhocInvoiceTemplateLine ======
Generated schema reference. Regenerate this page from the SQL unload; keep hand-maintained business notes in the narrative namespace.
===== Description =====
Lines for AdHoc Invoice Templates
===== Columns =====
^ Column ^ Type ^ Null ^ Default ^ Comment ^
| **AdhocInvoiceTemplateLineID** | char(20) | NOT NULL | | |
| AdhocInvoiceTemplateID | char(20) | NULL | | |
| Nominal | char(12) | NULL | | |
| Description | long varchar | NULL | | |
| VATCode | char(3) | NULL | | |
| Amount | double | NULL | | |
| LineNumber | smallint | NULL | | |
===== Primary Key =====
* AdhocInvoiceTemplateLineID
===== Foreign Keys =====
^ Constraint ^ Columns ^ References ^ Delete/update action ^
| AdhocInvoiceTemplate | AdhocInvoiceTemplateID | [[database:tables:pears_adhocinvoicetemplate|pears.AdhocInvoiceTemplate (AdhocInvoiceTemplateID)]] | ON DELETE CASCADE |
===== Referenced By =====
* No incoming foreign keys found.
===== Indexes =====
* No indexes found.
===== Triggers =====
* No triggers found.
===== Original SQL =====
-- IQX database structure split by table
-- Source: IQXDatabaseStructure - with comments.sql
-- Table: "pears"."AdhocInvoiceTemplateLine"
-- Table comment: Lines for AdHoc Invoice Templates
-- Statement count: 3
CREATE TABLE "pears"."AdhocInvoiceTemplateLine" (
"AdhocInvoiceTemplateLineID" char(20) NOT NULL
,"AdhocInvoiceTemplateID" char(20) NULL
,"Nominal" char(12) NULL
,"Description" long varchar NULL
,"VATCode" char(3) NULL
,"Amount" double NULL
,"LineNumber" smallint NULL
,PRIMARY KEY ("AdhocInvoiceTemplateLineID" ASC)
)
go
COMMENT ON TABLE "pears"."AdhocInvoiceTemplateLine" IS
'Lines for AdHoc Invoice Templates'
go
ALTER TABLE "pears"."AdhocInvoiceTemplateLine"
ADD FOREIGN KEY "AdhocInvoiceTemplate" ("AdhocInvoiceTemplateID" ASC)
REFERENCES "pears"."AdhocInvoiceTemplate" ("AdhocInvoiceTemplateID")
ON DELETE CASCADE
go