Database Reference
In-Depth Information
print 'Log schema created'
end
Else
print 'Log schema already exists.'
print ''
/* log.SSISAppInstance table */
If Not Exists(Select s.name + '.' + t.name
From sys.tables t
Join sys.schemas s
On s.schema_id = t.schema_id
Where s.name = 'log'
And t.name = 'SSISAppInstance')
begin
print 'Creating log.SSISAppInstance table'
Create Table [log].SSISAppInstance
(
AppInstanceID int identity(1,1)
Constraint PK_SSISAppInstance
Primary Key Clustered
,ApplicationID int Not Null
Constraint
FK_logSSISAppInstance_cfgApplication_ApplicationID
Foreign Key References cfg.Applications(ApplicationID)
,StartDateTime datetime Not Null
Constraint DF_cfgSSISAppInstance_StartDateTime
Default(GetDate())
,EndDateTime datetime Null
,[Status] varchar(12) Null
)
print 'Log.SSISAppInstance created'
end
Else
print 'Log.SSISAppInstance table already exists.'
print ''
/* log.LogStartOfApplication stored procedure */
If Exists(Select s.name + '.' + p.name
Search WWH ::




Custom Search