Tables [dbo].[MobileSetup]
Properties
PropertyValue
CollationSQL_Latin1_General_CP1_CI_AS
HeapYes
Row Count (~)0
Created8:24:48 AM Friday, December 7, 2018
Last Modified9:00:05 AM Friday, November 22, 2024
Columns
NameData TypeMax Length (Bytes)Allow NullsDefault
Primary Key PK_MobileSetup: MobileSetupIDForeign Keys FK_MobileSetup_MoversConnectSetup: [dbo].[MoversConnectSetup].MobileSetupIDCheck Constraints CK_MobileSetupID : ([MobileSetupID]=(1))MobileSetupIDint4
No
CompanyIDvarchar(15)15
Yes
UserNamevarchar(255)255
Yes
Passwordvarchar(500)500
Yes
Inactivebit1
No
((0))
Tokenvarchar(255)255
Yes
TokenObtaineddatetime8
Yes
TokenExpiresdatetime8
Yes
RefreshTokenvarchar(255)255
Yes
RefreshTokenExpiresdatetime8
Yes
DateModifieddatetime8
No
Foreign Keys FK_MobileSetup_Sysuser: [dbo].[Sysuser].ModifiedBySysUserFIDModifiedBySysUserFIDint4
No
ActivateMobileCrewbit1
No
((0))
ActivateCrewTimebit1
No
((0))
AllowMobilePasswordResetbit1
No
((0))
Foreign Keys FK_MobileSetup_DocumentType: [dbo].[DocumentType].DefaultDocumentTypeFIDDefaultDocumentTypeFIDint4
Yes
FuturePunchSecondsint4
Yes
CrewTimeForCrewLeadOnlybit1
No
((0))
LastSyncedDatedatetime8
Yes
Foreign Keys FK_MobileSetup_NoteType: [dbo].[NoteType].DefaultOrderNoteTypeFIDDefaultOrderNoteTypeFIDsmallint2
Yes
Foreign Keys FK_MobileSetup_ChangeOrderDocumentType: [dbo].[DocumentType].ChangeOrderDocumentTypeFIDChangeOrderDocumentTypeFIDint4
Yes
Foreign Keys FK_MobileSetup_JobSummaryDocumentType: [dbo].[DocumentType].JobSummaryDocumentTypeFIDJobSummaryDocumentTypeFIDint4
Yes
Foreign Keys FK_MobileSetup_JobDetailDocumentType: [dbo].[DocumentType].JobDetailDocumentTypeFIDJobDetailDocumentTypeFIDint4
Yes
Foreign Keys FK_MobileSetup_EmailNoteType: [dbo].[NoteType].EmailOrderNoteTypeFIDEmailOrderNoteTypeFIDsmallint2
Yes
MSCrewFromEmailAddressvarchar(50)50
Yes
MSCrewFromEmailDisplayNamevarchar(50)50
Yes
MSCrewFromEmailFooternvarchar(2000)4000
Yes
Check Constraints CK_CustomerSummaryRoundingMinutes : ([CustomerSummaryRoundingMinutes]=(30) OR [CustomerSummaryRoundingMinutes]=(15) OR [CustomerSummaryRoundingMinutes]=(0))CustomerSummaryRoundingMinutesint4
No
((0))
CustomerSummaryDetailedTimebit1
No
((0))
IsCrewTimeLockedbit1
No
((0))
IsCrewTimeForCrewLeadLockedbit1
No
((0))
AllowCrewAdditionsbit1
No
((0))
PastDaysToShowint4
Yes
FutureDaysToShowint4
Yes
Indexes Indexes
NameColumnsUnique
Primary Key PK_MobileSetup: MobileSetupIDPK_MobileSetupMobileSetupID
Yes
Check Constraints Check Constraints
NameOn ColumnConstraint
CK_CustomerSummaryRoundingMinutesCustomerSummaryRoundingMinutes([CustomerSummaryRoundingMinutes]=(30) OR [CustomerSummaryRoundingMinutes]=(15) OR [CustomerSummaryRoundingMinutes]=(0))
CK_MobileSetupIDMobileSetupID([MobileSetupID]=(1))
Foreign Keys Foreign Keys
NameColumns
FK_MobileSetup_ChangeOrderDocumentTypeChangeOrderDocumentTypeFID->[dbo].[DocumentType].[DocumentTypeID]
FK_MobileSetup_DocumentTypeDefaultDocumentTypeFID->[dbo].[DocumentType].[DocumentTypeID]
FK_MobileSetup_NoteTypeDefaultOrderNoteTypeFID->[dbo].[NoteType].[NoteTypeID]
FK_MobileSetup_EmailNoteTypeEmailOrderNoteTypeFID->[dbo].[NoteType].[NoteTypeID]
FK_MobileSetup_JobDetailDocumentTypeJobDetailDocumentTypeFID->[dbo].[DocumentType].[DocumentTypeID]
FK_MobileSetup_JobSummaryDocumentTypeJobSummaryDocumentTypeFID->[dbo].[DocumentType].[DocumentTypeID]
FK_MobileSetup_MoversConnectSetupMobileSetupID->[dbo].[MoversConnectSetup].[MoversConnectSetupID]
FK_MobileSetup_SysuserModifiedBySysUserFID->[dbo].[Sysuser].[SysUserID]
Permissions
TypeActionOwning Principal
GrantDeleteMssExec
GrantInsertMssExec
GrantSelectMssExec
GrantUpdateMssExec
SQL Script
CREATE TABLE [dbo].[MobileSetup]
(
[MobileSetupID] [int] NOT NULL,
[CompanyID] [varchar] (15) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[UserName] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Password] [varchar] (500) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Inactive] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_Inactive] DEFAULT ((0)),
[Token] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[TokenObtained] [datetime] NULL,
[TokenExpires] [datetime] NULL,
[RefreshToken] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[RefreshTokenExpires] [datetime] NULL,
[DateModified] [datetime] NOT NULL,
[ModifiedBySysUserFID] [int] NOT NULL,
[ActivateMobileCrew] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_ActivateMobileCrew] DEFAULT ((0)),
[ActivateCrewTime] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_ActivateCrewTime] DEFAULT ((0)),
[AllowMobilePasswordReset] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_AllowMobilePasswordReset] DEFAULT ((0)),
[DefaultDocumentTypeFID] [int] NULL,
[FuturePunchSeconds] [int] NULL,
[CrewTimeForCrewLeadOnly] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_CrewTimeForCrewLeadOnly] DEFAULT ((0)),
[LastSyncedDate] [datetime] NULL,
[DefaultOrderNoteTypeFID] [smallint] NULL,
[ChangeOrderDocumentTypeFID] [int] NULL,
[JobSummaryDocumentTypeFID] [int] NULL,
[JobDetailDocumentTypeFID] [int] NULL,
[EmailOrderNoteTypeFID] [smallint] NULL,
[MSCrewFromEmailAddress] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[MSCrewFromEmailDisplayName] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[MSCrewFromEmailFooter] [nvarchar] (2000) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[CustomerSummaryRoundingMinutes] [int] NOT NULL CONSTRAINT [DF_MobileSetup_CustomerSummaryRoundingMinutes] DEFAULT ((0)),
[CustomerSummaryDetailedTime] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_CustomerSummaryDetailedTime] DEFAULT ((0)),
[IsCrewTimeLocked] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_IsCrewTimeLocked] DEFAULT ((0)),
[IsCrewTimeForCrewLeadLocked] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_IsCrewTimeForCrewLeadLocked] DEFAULT ((0)),
[AllowCrewAdditions] [bit] NOT NULL CONSTRAINT [DF_MobileSetup_AllowCrewAdditions] DEFAULT ((0)),
[PastDaysToShow] [int] NULL,
[FutureDaysToShow] [int] NULL
) ON [PRIMARY]
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [CK_CustomerSummaryRoundingMinutes] CHECK (([CustomerSummaryRoundingMinutes]=(30) OR [CustomerSummaryRoundingMinutes]=(15) OR [CustomerSummaryRoundingMinutes]=(0)))
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [CK_MobileSetupID] CHECK (([MobileSetupID]=(1)))
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [PK_MobileSetup] PRIMARY KEY NONCLUSTERED  ([MobileSetupID]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_ChangeOrderDocumentType] FOREIGN KEY ([ChangeOrderDocumentTypeFID]) REFERENCES [dbo].[DocumentType] ([DocumentTypeID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_DocumentType] FOREIGN KEY ([DefaultDocumentTypeFID]) REFERENCES [dbo].[DocumentType] ([DocumentTypeID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_NoteType] FOREIGN KEY ([DefaultOrderNoteTypeFID]) REFERENCES [dbo].[NoteType] ([NoteTypeID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_EmailNoteType] FOREIGN KEY ([EmailOrderNoteTypeFID]) REFERENCES [dbo].[NoteType] ([NoteTypeID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_JobDetailDocumentType] FOREIGN KEY ([JobDetailDocumentTypeFID]) REFERENCES [dbo].[DocumentType] ([DocumentTypeID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_JobSummaryDocumentType] FOREIGN KEY ([JobSummaryDocumentTypeFID]) REFERENCES [dbo].[DocumentType] ([DocumentTypeID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_MoversConnectSetup] FOREIGN KEY ([MobileSetupID]) REFERENCES [dbo].[MoversConnectSetup] ([MoversConnectSetupID])
GO
ALTER TABLE [dbo].[MobileSetup] ADD CONSTRAINT [FK_MobileSetup_Sysuser] FOREIGN KEY ([ModifiedBySysUserFID]) REFERENCES [dbo].[Sysuser] ([SysUserID])
GO
GRANT SELECT ON  [dbo].[MobileSetup] TO [MssExec]
GRANT INSERT ON  [dbo].[MobileSetup] TO [MssExec]
GRANT DELETE ON  [dbo].[MobileSetup] TO [MssExec]
GRANT UPDATE ON  [dbo].[MobileSetup] TO [MssExec]
GO
Uses
Used By