Tutorial :How to create Log file in SSIS



Question:

I want to create a log file in SSIS. I know how to create through management studio, but I wanted to run my SSIS package through Command Prompt. Can you help me find the Windows commands for that?


Solution:1

You can use the /L option, as documented here; however, you can also set Logging up in a much easier and finer way through the SSIS>Logging menu in Visual Studio.

Cheers,
Eric


Solution:2

In your SSIS you need to create and configure an SSIS Log provider before you can use it. Look into link text for more info.


Solution:3

You need to set up the a new connection string inside of Business Intelligence Development Studio (BIDS). where you have to specify the path of Log file...i mean here path will be D:\Sample_Examples\Log.log... and name of the connection manager will be Log.log so now the command prompt will get changed into

dtexec /f "C:\\Package.dtsx" /l "DTS.LogProviderTextFile";"Log.log"  

instead of

dtexec /f "C:\\Package.dtsx" /l "DTS.LogProviderTextFile;D:\Sample_Examples\Log.log"  

we cant specify a direct path after DTS.LogProviderTextFile...because of that only i got error...

Thank you very much for the suggestions...


Solution:4

You can do this another way, without going into your SSIS package.

Create a batch file and run DTEXEC in a new instance of CMD, i.e.:

CMD /C DTEXEC your package and args > log file

When you do this, you can run this batch file and get your log file.

See http://richarddingwall.name/2009/01/26/capture-the-output-from-a-scheduled-task/ for more details


Solution:5

Yes, you have to create a connection manager for the log provider; however; there is no documentation on how to do this if you are using a custom log provider.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »