{ "name": "pl_LoadDateBatches", "properties": { "description": "load data in date batches", "activities": [ { "name": "set_NumBatches", "type": "SetVariable", "dependsOn": [], "userProperties": [], "typeProperties": { "variableName": "v_NumBatches", "value": { "value": "@string(div(pipeline().parameters.pdaysBack, pipeline().parameters.pdaysBatches))", "type": "Expression" } } }, { "name": "Make 0 to NumBatches", "type": "SetVariable", "dependsOn": [ { "activity": "set_NumBatches", "dependencyConditions": [ "Succeeded" ] } ], "userProperties": [], "typeProperties": { "variableName": "range", "value": { "value": "@range(1,int(variables('v_NumBatches')))", "type": "Expression" } } }, { "name": "For each interval", "type": "ForEach", "dependsOn": [ { "activity": "Make 0 to NumBatches", "dependencyConditions": [ "Succeeded" ] } ], "userProperties": [], "typeProperties": { "items": { "value": "@variables('range')", "type": "Expression" }, "isSequential": false, "activities": [ { "name": "v_StartDate", "type": "SetVariable", "dependsOn": [], "userProperties": [] }, { "name": "v_EndDate", "type": "SetVariable", "dependsOn": [ { "activity": "v_StartDate", "dependencyConditions": [ "Succeeded" ] } ], "userProperties": [], "typeProperties": { "variableName": "v_EndDate", "value": "" } } ] } } ], "parameters": { "pdaysBack": { "type": "int", "defaultValue": 20 }, "pdaysBatches": { "type": "int", "defaultValue": 4 } }, "variables": { "v_NumBatches": { "type": "String" }, "range": { "type": "Array" }, "v_StartDate": { "type": "String" }, "v_EndDate": { "type": "String" } }, "folder": { "name": "Aspect/Test" }, "annotations": [] } }