Run the Stored procedure , loop through dates in SSIS

  • I have a ssis package , where i need to get the start date and end date ( from audit log table ) and pass the dates to run SP,  through a loop.

    I have set date variables :

    1) startdate ='10/13/2023' ( which comes from audit log table )

    2) Enddate varible ='10/15/2023' ( which is getdate()-1) for now.

    I have a stored procedure "Procedure_1"  with date parameter @extractdate

    Based on start and enddate , I need to loop through dates and pass the dates to the above stored procedure

    Example: From above start and enddates , we need to run the sp for 10/13/2023 , 10/14/2023/10/15/2023.

    so my procedure should run 3 times ( one date at a time)

    1) " EXECUTE Procedure_1 '10/13/2023' "

    2) " EXECUTE Procedure_1 '10/14/2023' "

    3) " EXECUTE Procedure_1 '10/15/2023' "

    How can i achieve this?

    • This topic was modified 1 year, 1 month ago by  komal145.
  • Thanks for posting your issue and hopefully someone will answer soon.

    This is an automated bump to increase visibility of your question.

Viewing 2 posts - 1 through 1 (of 1 total)

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