Tables [dbo].[GLAssetJournal]
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)0
Created12:57:22 AM Thursday, March 21, 2019
Last Modified1:10:55 AM Thursday, March 21, 2019
KeyNameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Cluster Primary Key PK_GLAssetJournal: JournalIDJournalIDint4
False
1 - 1
JournalNumbervarchar(15)15
False
Batchvarchar(15)15
False
('')
Typechar(2)2
False
Datedatetime8
False
DatePeriodint4
False
Periodint4
False
Descriptionvarchar(255)255
False
Amountmoney8
False
((0))
Foreign Keys FK_GLAssetJournal_TransactionTypeID_ShTransactionTypes: [dbo].[ShTransactionTypes].TransactionTypeIDTransactionTypeIDint4
False
Foreign Keys FK_GLAssetJournal_VoidID_GLAssetJournal: [dbo].[GLAssetJournal].VoidIDVoidIDint4
True
Voidbit1
False
((0))
CreatorIDchar(8)8
False
UpdatorIDchar(8)8
False
CreateDatedatetime8
False
(getdate())
LastUpdatedatetime8
False
(getdate())
KeyNameKey ColumnsUniqueFill Factor
Cluster Primary Key PK_GLAssetJournal: JournalIDPK_GLAssetJournalJournalID
True
80
NameColumns
FK_GLAssetJournal_TransactionTypeID_ShTransactionTypesTransactionTypeID->[dbo].[ShTransactionTypes].[TransactionTypeID]
FK_GLAssetJournal_VoidID_GLAssetJournalVoidID->[dbo].[GLAssetJournal].[JournalID]
CREATE TABLE [dbo].[GLAssetJournal]
(
[JournalID] [int] NOT NULL IDENTITY(1, 1),
[JournalNumber] [varchar] (15) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[Batch] [varchar] (15) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL CONSTRAINT [DF_GLAssetJournal_Batch] DEFAULT (''),
[Type] [char] (2) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[Date] [datetime] NOT NULL,
[DatePeriod] [int] NOT NULL,
[Period] [int] NOT NULL,
[Description] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[Amount] [money] NOT NULL CONSTRAINT [DF_GLAssetJournal_Amount] DEFAULT ((0)),
[TransactionTypeID] [int] NOT NULL,
[VoidID] [int] NULL,
[Void] [bit] NOT NULL CONSTRAINT [DF_GLAssetJournal_Void] DEFAULT ((0)),
[CreatorID] [char] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[UpdatorID] [char] (8) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[CreateDate] [datetime] NOT NULL CONSTRAINT [DF_GLAssetJournal_CreateDate] DEFAULT (getdate()),
[LastUpdate] [datetime] NOT NULL CONSTRAINT [DF_GLAssetJournal_LastUpdate] DEFAULT (getdate())
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[GLAssetJournal] ADD CONSTRAINT [PK_GLAssetJournal] PRIMARY KEY CLUSTERED  ([JournalID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[GLAssetJournal] ADD CONSTRAINT [FK_GLAssetJournal_TransactionTypeID_ShTransactionTypes] FOREIGN KEY ([TransactionTypeID]) REFERENCES [dbo].[ShTransactionTypes] ([TransactionTypeID])
GO
ALTER TABLE [dbo].[GLAssetJournal] ADD CONSTRAINT [FK_GLAssetJournal_VoidID_GLAssetJournal] FOREIGN KEY ([VoidID]) REFERENCES [dbo].[GLAssetJournal] ([JournalID])
GO