Search code examples
sql-serverssissql-server-2012sql-server-data-toolssql-server-agent

Lock an SSIS package from multiple simultaneous executions


I have an SSIS package(Package1.dtsx) that been deployed to SSISDB. currently I scheduled the package with some parameters in sql server agent.

how do I lock the package(Package1.dtsx) if someone try to attempt running it in another sql server agent job with different parameters.


Solution

  • You can do this yourself by adding a flag and having your package check this flag before processing. Either quit out, loop until flag is clear or some other logic.

    I personally have only ever had one agent per package and the agent handles the multiple execution scenarios.