Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
ageshbabu
Starting Member
1 Post |
Posted - 2010-12-16 : 14:08:41
|
Hi, I have this piece of code which inserts data into dailyLoanstomail table and in the package I use this table as a source and destination to CSV file. The package runs by itself perfectly but when I try to run in the proc as shown below seems like its running forever without ending, so I used sp_who2 to check whats going on, Actually I saw one process is blocking the other(SSIS vs insert). Does any one have the soultion for this?begin try begin transaction declare @ssis_SE1 varchar(100) declare @ssis_SE2 varchar(100) declare @ssis_SE3 varchar(200) declare @Subjectt varchar(150) insert into dailyLoanstomail select *,'12' as cust_id from dbo.[RRALoans] set @ssis_SE1 = 'dtexec /dts "\FileSystem\LoansExport" /server BBBank' set @ssis_SE2 = ' > c:\ProcessingTemp\Loans\LoansLog.txt' set @ssis_SE3 = @ssis_SE1 + @ssis_SE2 EXEC master..xp_CMDShell @ssis_SE3 commit transaction end try begin catch--Rolling back any open transactions while @@TRANCOUNT > 0 rollback transaction --Logging the errors to the ErrorHandling table exec dbo.procErrorHandling 'Processing' end catch |
|
|
|
|