Running Windows batch script

  • Can i know is there any way of calling/running a windows batch file using powershell script or SSIS or perl.

    I have to simply execute a .bat file.

  • You can use the Execute Process task in SSIS.

    John

  • you can use batch file execution using Powershell script.....

    Sagar Sonawane
    ** Every DBA has his day!!:cool:

  • Hi Saga,

    Can you please give me the sample code of calling a batch file from powershell script.

    This batch file should execute only if the file say "extract_name.txt" exists on my disk location(say J:\extract\).

    Thanks alot..

  • In PowerShell you can invoke cmd.exe directly with a /c and you can use Test-Path to check for the existence of a file.

    There are no special teachers of virtue, because virtue is taught by the whole community.
    --Plato

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply