Trigger ADF Pipeline on second Friday from end of month and on Tues, Wed and Thurs of the same week.

%3CLINGO-SUB%20id%3D%22lingo-sub-2288810%22%20slang%3D%22en-US%22%3ETrigger%20ADF%20Pipeline%20on%20second%20Friday%20from%20end%20of%20month%20and%20on%20Tues%2C%20Wed%20and%20Thurs%20of%20the%20same%20week.%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2288810%22%20slang%3D%22en-US%22%3E%3CP%3EI%20need%20a%20Pipeline%20to%20trigger%20on%20the%20Monthend%20week%20(Tues%2C%20Wed%2C%20Thurs%20and%20Friday)%20of%20a%20month.%3C%2FP%3E%3CP%3EMonthend%20is%20defined%20as%2C%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3E%22Last%20but%20one%22%20Friday%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3EOr%3CSPAN%3E%26nbsp%3B%3C%2FSPAN%3ESecond%20Friday%20from%20the%20end%20of%20the%20month.%3C%2FP%3E%3CP%3EFor%20Example%2C%20For%20month%20of%20June%202021%2C%2018th%20is%20the%20Monthend%20(Orange%20color%20as%20shown%20in%20the%20image).%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-left%22%20image-alt%3D%22Calendar.jpg%22%20style%3D%22width%3A%20200px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F275420i18013C777A6AA05E%2Fimage-size%2Fsmall%3Fv%3Dv2%26amp%3Bpx%3D200%22%20role%3D%22button%22%20title%3D%22Calendar.jpg%22%20alt%3D%22Calendar.jpg%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3EIf%20its%20just%20on%20Monthend%20i.e.%20Second%20Friday%20from%20the%20end%20of%20calendar%20month%2C%20its%20easy.%20Just%20use%20Occurrance%20as%20-2%20and%20day%20as%20Friday%20in%20the%20Scheduled%20trigger%20and%20add%20to%20a%20pipeline%20to%20trigger%2C%3C%2FP%3E%3CPRE%3E%22schedule%22%3A%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22monthlyOccurrences%22%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%7B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22day%22%3A%20%22Friday%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22occurrence%22%3A%20-2%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%7D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%7D%3C%2FPRE%3E%3CP%3Ebut%20I%20also%20need%20to%20run%20on%20the%20Tues%2C%20Wed%20and%20Thurs%20of%20the%20same%20week%2C%20which%20I%20find%20it%20difficult%20as%20these%20weekdays%20can%20be%20second%20or%20third%20from%20the%20end%20of%20the%20calendar%20month.%20For%20example%3A%20For%20June%202021%2C%20as%20shown%20in%20the%20image%2C%20I%20also%20need%20to%20run%20on%2015th%20(Third%20Tuesday%20from%20the%20end%20of%20calendar%20month)%2C%2016th%20(Third%20Wednesday%20from%20the%20end%20of%20calendar%20month)%2C%2017th%20(Second%20Thursday%20from%20the%20end%20of%20calendar%20month).%3C%2FP%3E%3CP%3ECan%20you%20let%20me%20know%20if%20this%20can%20be%20implemented%20using%20triggers%20of%20Azure%20data%20factory%3F%20If%20not%2C%20any%20other%20ways%20of%20implementing%3F%20Thank%20You!%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

I need a Pipeline to trigger on the Monthend week (Tues, Wed, Thurs and Friday) of a month.

Monthend is defined as, "Last but one" Friday Or Second Friday from the end of the month.

For Example, For month of June 2021, 18th is the Monthend (Orange color as shown in the image).

Calendar.jpg

If its just on Monthend i.e. Second Friday from the end of calendar month, its easy. Just use Occurrance as -2 and day as Friday in the Scheduled trigger and add to a pipeline to trigger,

"schedule": {
                    "monthlyOccurrences": [
                        {
                            "day": "Friday",
                            "occurrence": -2
                        }
                    ]
                }

but I also need to run on the Tues, Wed and Thurs of the same week, which I find it difficult as these weekdays can be second or third from the end of the calendar month. For example: For June 2021, as shown in the image, I also need to run on 15th (Third Tuesday from the end of calendar month), 16th (Third Wednesday from the end of calendar month), 17th (Second Thursday from the end of calendar month).

Can you let me know if this can be implemented using triggers of Azure data factory? If not, any other ways of implementing? Thank You!

0 Replies