Tables [dbo].[LdViews]
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
Row Count (~)0
Created12:55:55 AM Thursday, March 21, 2019
Last Modified1:12:36 AM Thursday, March 21, 2019
KeyNameData TypeMax Length (Bytes)Allow NullsIdentityDefault
Cluster Primary Key PK_LdViews: ViewIDViewIDint4
False
1 - 1
ViewNamevarchar(64)64
False
DisplayNamevarchar(128)128
False
Descriptionvarchar(128)128
False
Foreign Keys FK_LdViews_BaseID_LdBases: [dbo].[LdBases].BaseIDBaseIDint4
False
Custombit1
False
Foreign Keys FK_LdViews_BaseViewID_LdViews: [dbo].[LdViews].BaseViewIDBaseViewIDint4
True
Sharedbit1
False
CreatorIDchar(8)8
False
UpdatorIDchar(8)8
False
CreateDatedatetime8
False
(getdate())
LastUpdatedatetime8
False
(getdate())
TimeStamptimestamp8
True
SQLViewNamevarchar(128)128
True
LastUsedFilterint4
True
CreateSQLViewbit1
False
((0))
Foreign Keys FK_LdViews_SQLViewApplicationID_LdSQLViewApplications: [dbo].[LdSQLViewApplications].SQLViewApplicationIDSQLViewApplicationIDint4
True
Foreign Keys FK_LdViews_ViewGroupID_LdViewGroups: [dbo].[LdViewGroups].ViewGroupIDViewGroupIDint4
False
KeyNameKey ColumnsUniqueFill Factor
Cluster Primary Key PK_LdViews: ViewIDPK_LdViewsViewID
True
80
NameColumns
FK_LdViews_BaseID_LdBasesBaseID->[dbo].[LdBases].[BaseID]
FK_LdViews_BaseViewID_LdViewsBaseViewID->[dbo].[LdViews].[ViewID]
FK_LdViews_SQLViewApplicationID_LdSQLViewApplicationsSQLViewApplicationID->[dbo].[LdSQLViewApplications].[ApplicationID]
FK_LdViews_ViewGroupID_LdViewGroupsViewGroupID->[dbo].[LdViewGroups].[ViewGroupID]
CREATE TABLE [dbo].[LdViews]
(
[ViewID] [int] NOT NULL IDENTITY(1, 1),
[ViewName] [varchar] (64) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[DisplayName] [varchar] (128) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[Description] [varchar] (128) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL,
[BaseID] [int] NOT NULL,
[Custom] [bit] NOT NULL,
[BaseViewID] [int] NULL,
[Shared] [bit] NOT NULL,
[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_LdViews_CreateDate] DEFAULT (getdate()),
[LastUpdate] [datetime] NOT NULL CONSTRAINT [DF_LdViews_LastUpdate] DEFAULT (getdate()),
[TimeStamp] [timestamp] NULL,
[SQLViewName] [varchar] (128) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[LastUsedFilter] [int] NULL,
[CreateSQLView] [bit] NOT NULL CONSTRAINT [DF_LdViews_CreateSQLView] DEFAULT ((0)),
[SQLViewApplicationID] [int] NULL,
[ViewGroupID] [int] NOT NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[LdViews] ADD CONSTRAINT [PK_LdViews] PRIMARY KEY CLUSTERED  ([ViewID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[LdViews] ADD CONSTRAINT [FK_LdViews_BaseID_LdBases] FOREIGN KEY ([BaseID]) REFERENCES [dbo].[LdBases] ([BaseID])
GO
ALTER TABLE [dbo].[LdViews] ADD CONSTRAINT [FK_LdViews_BaseViewID_LdViews] FOREIGN KEY ([BaseViewID]) REFERENCES [dbo].[LdViews] ([ViewID])
GO
ALTER TABLE [dbo].[LdViews] ADD CONSTRAINT [FK_LdViews_SQLViewApplicationID_LdSQLViewApplications] FOREIGN KEY ([SQLViewApplicationID]) REFERENCES [dbo].[LdSQLViewApplications] ([ApplicationID])
GO
ALTER TABLE [dbo].[LdViews] ADD CONSTRAINT [FK_LdViews_ViewGroupID_LdViewGroups] FOREIGN KEY ([ViewGroupID]) REFERENCES [dbo].[LdViewGroups] ([ViewGroupID])
GO