Please look at the Faruk Celik Blog.This will hep you.
I had the same proplem in SSIS 2008 64 bit Environment. Scrript task does not get in to Break Point. I over come this issue by following the bellow article. Thanks Faruk Celik.
http://blogs.msdn.com/farukcelik/archive/2010/03/17/why-the-breakpoints-that-i-set-in-my-script-task-not-script-component-in-the-data-flow-never-hits.aspx
Thanks
Wednesday, May 19, 2010
Thursday, April 15, 2010
Export Table Row in to CSV File
Step1: Create Procedure with Select Statement
Create Procedure pcget_ETLErrorlog
AS
BEGIN
SELECT * FROM ETLErrorlog
END
Step 2:
DECLARE @SQL VARCHAR(2000)
DECLARE @ExportResult INT
SET @SQL = 'bcp "EXEC [MyDatabase].[dbo].pcget_ETLErrorlog" queryout "C:\Configuration V1\Global Alert\ETLAlert.CSV" -c -t, -T -S ServerName'
EXEC master..xp_cmdshell @SQL
Note: Procedure can be replaced directly by Select Statment "SELECT * FROM ETLErrorlog"
This will return the list of Output rows. If we dont want the out put rows then we can run the above query like this...
EXEC @ExportResult = master..xp_cmdshell @SQL,NO_OUTPUT
SELECT @ExportResult
Note:
If the OutPut Result is 0 then It means no error. This will help you to validate and proceed the next step.
Create Procedure pcget_ETLErrorlog
AS
BEGIN
SELECT * FROM ETLErrorlog
END
Step 2:
DECLARE @SQL VARCHAR(2000)
DECLARE @ExportResult INT
SET @SQL = 'bcp "EXEC [MyDatabase].[dbo].pcget_ETLErrorlog" queryout "C:\Configuration V1\Global Alert\ETLAlert.CSV" -c -t, -T -S ServerName'
EXEC master..xp_cmdshell @SQL
Note: Procedure can be replaced directly by Select Statment "SELECT * FROM ETLErrorlog"
This will return the list of Output rows. If we dont want the out put rows then we can run the above query like this...
EXEC @ExportResult = master..xp_cmdshell @SQL,NO_OUTPUT
SELECT @ExportResult
Note:
If the OutPut Result is 0 then It means no error. This will help you to validate and proceed the next step.
Subscribe to:
Posts (Atom)
