Tables [dbo].[ARAPReceivablePayableDistributions]
PropertyValue
Row Count (~)0
Created12:55:50 AM Thursday, March 21, 2019
Last Modified1:10:22 AM Thursday, March 21, 2019
KeyNameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Cluster Primary Key PK__ARAPRece__7EFF043E6F44D590: ReceivablePayableDistributionIDReceivablePayableDistributionIDint4
False
1 - 1
Foreign Keys FK_ARAPReceivablePayableDistributions_ReceivablePayableID_ARAPReceivablePayables: [dbo].[ARAPReceivablePayables].ReceivablePayableIDReceivablePayableIDint4
False
SourceDetailIDint4
True
SourceDetailID2int4
True
Foreign Keys FK_ARAPReceivablePayableDistributions_GLID_GLAccounts: [dbo].[GLAccounts].GLIDGLIDint4
False
Foreign Keys FK_ARAPReceivablePayableDistributions_BranchID_GLBranches: [dbo].[GLBranches].BranchIDBranchIDint4
False
Foreign Keys FK_ARAPReceivablePayableDistributions_DivisionID_GLDivisions: [dbo].[GLDivisions].DivisionIDDivisionIDint4
False
Foreign Keys FK_ARAPReceivablePayableDistributions_BalanceSheetGroupID_GLBalanceSheetGroups: [dbo].[GLBalanceSheetGroups].BalanceSheetGroupIDBalanceSheetGroupIDint4
False
GLTypeIDint4
False
DistTypeIDint4
False
Amountmoney8
False
TermDiscountmoney8
False
OpenAmountmoney8
False
Freightmoney8
False
((0))
Discountmoney8
False
((0))
Taxmoney8
False
((0))
Feemoney8
False
((0))
Foreign Keys FK_ARAPReceivablePayableDistributions_IntercompanyGLID_GLAccounts: [dbo].[GLAccounts].IntercompanyGLIDIntercompanyGLIDint4
True
Foreign Keys FK_ARAPReceivablePayableDistributions_CashbookIntercompanyGLID_GLAccounts: [dbo].[GLAccounts].CashbookIntercompanyGLIDCashbookIntercompanyGLIDint4
True
TermDiscountBaseAmountmoney8
False
((0))
KeyNameKey ColumnsUniqueFill Factor
Cluster Primary Key PK__ARAPRece__7EFF043E6F44D590: ReceivablePayableDistributionIDPK__ARAPRece__7EFF043E6F44D590ReceivablePayableDistributionID
True
80
NameColumns
FK_ARAPReceivablePayableDistributions_BalanceSheetGroupID_GLBalanceSheetGroupsBalanceSheetGroupID->[dbo].[GLBalanceSheetGroups].[BalanceSheetGroupID]
FK_ARAPReceivablePayableDistributions_BranchID_GLBranchesBranchID->[dbo].[GLBranches].[BranchID]
FK_ARAPReceivablePayableDistributions_CashbookIntercompanyGLID_GLAccountsCashbookIntercompanyGLID->[dbo].[GLAccounts].[AccountID]
FK_ARAPReceivablePayableDistributions_DivisionID_GLDivisionsDivisionID->[dbo].[GLDivisions].[DivisionID]
FK_ARAPReceivablePayableDistributions_GLID_GLAccountsGLID->[dbo].[GLAccounts].[AccountID]
FK_ARAPReceivablePayableDistributions_IntercompanyGLID_GLAccountsIntercompanyGLID->[dbo].[GLAccounts].[AccountID]
FK_ARAPReceivablePayableDistributions_ReceivablePayableID_ARAPReceivablePayablesReceivablePayableID->[dbo].[ARAPReceivablePayables].[ReceivablePayableID]
CREATE TABLE [dbo].[ARAPReceivablePayableDistributions]
(
[ReceivablePayableDistributionID] [int] NOT NULL IDENTITY(1, 1),
[ReceivablePayableID] [int] NOT NULL,
[SourceDetailID] [int] NULL,
[SourceDetailID2] [int] NULL,
[GLID] [int] NOT NULL,
[BranchID] [int] NOT NULL,
[DivisionID] [int] NOT NULL,
[BalanceSheetGroupID] [int] NOT NULL,
[GLTypeID] [int] NOT NULL,
[DistTypeID] [int] NOT NULL,
[Amount] [money] NOT NULL,
[TermDiscount] [money] NOT NULL,
[OpenAmount] [money] NOT NULL,
[Freight] [money] NOT NULL CONSTRAINT [DF_ARAPReceivablePayableDistributions_Freight] DEFAULT ((0)),
[Discount] [money] NOT NULL CONSTRAINT [DF_ARAPReceivablePayableDistributions_Discount] DEFAULT ((0)),
[Tax] [money] NOT NULL CONSTRAINT [DF_ARAPReceivablePayableDistributions_Tax] DEFAULT ((0)),
[Fee] [money] NOT NULL CONSTRAINT [DF_ARAPReceivablePayableDistributions_Fee] DEFAULT ((0)),
[IntercompanyGLID] [int] NULL,
[CashbookIntercompanyGLID] [int] NULL,
[TermDiscountBaseAmount] [money] NOT NULL CONSTRAINT [DF_ARAPReceivablePayableDistributions_TermDiscountBaseAmount] DEFAULT ((0))
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [PK__ARAPRece__7EFF043E6F44D590] PRIMARY KEY CLUSTERED  ([ReceivablePayableDistributionID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_BalanceSheetGroupID_GLBalanceSheetGroups] FOREIGN KEY ([BalanceSheetGroupID]) REFERENCES [dbo].[GLBalanceSheetGroups] ([BalanceSheetGroupID])
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_BranchID_GLBranches] FOREIGN KEY ([BranchID]) REFERENCES [dbo].[GLBranches] ([BranchID])
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_CashbookIntercompanyGLID_GLAccounts] FOREIGN KEY ([CashbookIntercompanyGLID]) REFERENCES [dbo].[GLAccounts] ([AccountID])
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_DivisionID_GLDivisions] FOREIGN KEY ([DivisionID]) REFERENCES [dbo].[GLDivisions] ([DivisionID])
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_GLID_GLAccounts] FOREIGN KEY ([GLID]) REFERENCES [dbo].[GLAccounts] ([AccountID])
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_IntercompanyGLID_GLAccounts] FOREIGN KEY ([IntercompanyGLID]) REFERENCES [dbo].[GLAccounts] ([AccountID])
GO
ALTER TABLE [dbo].[ARAPReceivablePayableDistributions] ADD CONSTRAINT [FK_ARAPReceivablePayableDistributions_ReceivablePayableID_ARAPReceivablePayables] FOREIGN KEY ([ReceivablePayableID]) REFERENCES [dbo].[ARAPReceivablePayables] ([ReceivablePayableID])
GO