SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
DECLARE
@DB VARCHAR(20),
@DUMP_ID VARCHAR(50),
@DUMP_TYPE VARCHAR(10),
@RECEIVED_DT varchar(10),
@UPLOAD_DATE VARCHAR(30),
@UPDATED_BY VARCHAR(10),
@DEBUG BIT
SET @DB ='ADVENTNET'
SET @DUMP_ID = 'ADVENTNET_1'
SET @DUMP_TYPE = 'MASTER'
SET @RECEIVED_DT = '08/23/2010'
SET @UPLOAD_DATE = '08/25/2010'
SET @UPDATED_BY = 'AKJ4232'
SET @DEBUG = 0
SET NOCOUNT OFF
declare @cmd varchar(1000)
declare @ssispath varchar(1000)
declare @DTS_ExePath varchar(1000)
set @ssispath = 'E:\SSIS\ADVENTNET\ADVENTNET\ADVENTNET\ADVENTNET_DOTNETDumpUpload.dtsx'
select @cmd = '""C:\Program Files (x86)\Microsoft SQL Server\90\DTS\Binn\DTExec.exe"/F "' + @ssispath + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::DB].Properties[Value];"' + @DB + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::DumpIndicator].Properties[Value];"' + @DUMP_ID + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::DumpType].Properties[Value];"' + @DUMP_TYPE + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::RecvdDt].Properties[Value];"' + @RECEIVED_DT + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::UpldBy].Properties[Value];"' + @UPDATED_BY + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::UpldDt].Properties[Value];"' + @UPLOAD_DATE + '"'
select @cmd = @cmd + ' /SET \Package.Variables[User::SSISPath].Properties[Value];"' + @SSISPATH + '"'
set @cmd = rtrim(ltrim(@cmd))
print @cmd
exec master..xp_cmdshell @cmd
SET NOCOUNT ON;
SET ANSI_NULLS OFF
GO
SET QUOTED_IDENTIFIER OFF
GO
|