Tables [dbo].[ShTaxAuthorityTaxFlags]
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)0
Created1:00:44 AM Thursday, March 21, 2019
Last Modified1:15:34 AM Thursday, March 21, 2019
KeyNameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Cluster Primary Key PK__ShTaxAut__667F076AEB531C0F: AuthorityTaxFlagIDAuthorityTaxFlagIDint4
False
1 - 1
Foreign Keys FK_ShTaxAuthorityTaxFlags_TaxAuthorityID_ShTaxAuthorities: [dbo].[ShTaxAuthorities].TaxAuthorityIDTaxAuthorityIDint4
False
OverrideRatedecimal(18,6)9
True
RateTypeint4
True
Foreign Keys FK_ShTaxAuthorityTaxFlags_TaxFlagID_ShTaxFlags: [dbo].[ShTaxFlags].TaxFlagIDTaxFlagIDint4
False
TaxFlagint4
False
Foreign Keys FK_ShTaxAuthorityTaxFlags_ItemUnitExceptionID_shTaxExceptions: [dbo].[shTaxExceptions].ItemUnitExceptionIDItemUnitExceptionIDint4
True
Foreign Keys FK_ShTaxAuthorityTaxFlags_TaxFlagExceptionID_shTaxExceptions: [dbo].[shTaxExceptions].TaxFlagExceptionIDTaxFlagExceptionIDint4
True
CreatorIDvarchar(8)8
False
UpdatorIDvarchar(8)8
False
CreateDatedatetime8
False
(getdate())
LastUpdatedatetime8
False
(getdate())
KeyNameKey ColumnsUniqueFill Factor
Cluster Primary Key PK__ShTaxAut__667F076AEB531C0F: AuthorityTaxFlagIDPK__ShTaxAut__667F076AEB531C0FAuthorityTaxFlagID
True
80
NameColumns
FK_ShTaxAuthorityTaxFlags_ItemUnitExceptionID_shTaxExceptionsItemUnitExceptionID->[dbo].[shTaxExceptions].[ExceptionCodeID]
FK_ShTaxAuthorityTaxFlags_TaxAuthorityID_ShTaxAuthoritiesTaxAuthorityID->[dbo].[ShTaxAuthorities].[TaxAuthorityID]
FK_ShTaxAuthorityTaxFlags_TaxFlagExceptionID_shTaxExceptionsTaxFlagExceptionID->[dbo].[shTaxExceptions].[ExceptionCodeID]
FK_ShTaxAuthorityTaxFlags_TaxFlagID_ShTaxFlagsTaxFlagID->[dbo].[ShTaxFlags].[TaxFlagID]
CREATE TABLE [dbo].[ShTaxAuthorityTaxFlags]
(
[AuthorityTaxFlagID] [int] NOT NULL IDENTITY(1, 1),
[TaxAuthorityID] [int] NOT NULL,
[OverrideRate] [decimal] (18, 6) NULL,
[RateType] [int] NULL,
[TaxFlagID] [int] NOT NULL,
[TaxFlag] [int] NOT NULL,
[ItemUnitExceptionID] [int] NULL,
[TaxFlagExceptionID] [int] NULL,
[CreatorID] [varchar] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[UpdatorID] [varchar] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[CreateDate] [datetime] NOT NULL CONSTRAINT [DF_ShTaxAuthorityTaxFlags_CreateDate] DEFAULT (getdate()),
[LastUpdate] [datetime] NOT NULL CONSTRAINT [DF_ShTaxAuthorityTaxFlags_LastUpdate] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ShTaxAuthorityTaxFlags] ADD CONSTRAINT [PK__ShTaxAut__667F076AEB531C0F] PRIMARY KEY CLUSTERED  ([AuthorityTaxFlagID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ShTaxAuthorityTaxFlags] ADD CONSTRAINT [FK_ShTaxAuthorityTaxFlags_ItemUnitExceptionID_shTaxExceptions] FOREIGN KEY ([ItemUnitExceptionID]) REFERENCES [dbo].[shTaxExceptions] ([ExceptionCodeID])
GO
ALTER TABLE [dbo].[ShTaxAuthorityTaxFlags] ADD CONSTRAINT [FK_ShTaxAuthorityTaxFlags_TaxAuthorityID_ShTaxAuthorities] FOREIGN KEY ([TaxAuthorityID]) REFERENCES [dbo].[ShTaxAuthorities] ([TaxAuthorityID])
GO
ALTER TABLE [dbo].[ShTaxAuthorityTaxFlags] ADD CONSTRAINT [FK_ShTaxAuthorityTaxFlags_TaxFlagExceptionID_shTaxExceptions] FOREIGN KEY ([TaxFlagExceptionID]) REFERENCES [dbo].[shTaxExceptions] ([ExceptionCodeID])
GO
ALTER TABLE [dbo].[ShTaxAuthorityTaxFlags] ADD CONSTRAINT [FK_ShTaxAuthorityTaxFlags_TaxFlagID_ShTaxFlags] FOREIGN KEY ([TaxFlagID]) REFERENCES [dbo].[ShTaxFlags] ([TaxFlagID])
GO