Split In Batches node currentRunIndex example — Workflow n8n

Faible complexité Déclencheur5 nœuds🏷️ Miscellaneous👁 2,768 vuespar Harshil Agrawal

Aperçu

This workflow demonstrates how to use currentRunIndex to get the running index.

Function node: This node generates mock data for the workflow. Replace it with the node whose data you want to split into batches.

SplitInBatches node: This node splits the data with the batch size equal to 1. Based on your use-case, set the value of the Batch Size.

IF node: This node checks the running index. If the running index equals 5 the node returns true and breaks the loop. The node uses the expression {

Nœuds utilisés

On clicking 'execute'FunctionSplitInBatchesIFSet

Aperçu du workflow

O
On clicking 'execute'
F
Function
S
SplitInBatches
I
IF
S
Set
5 nodes5 edges

Comment ça fonctionne

  1. 1

    Déclencheur

    Le workflow démarre avec un déclencheur déclencheur.

  2. 2

    Traitement

    Les données transitent par 5 nœuds, connecting function, if, manualtrigger.

  3. 3

    Sortie

    Le workflow termine son automatisation et livre le résultat à la destination configurée.

Détails des nœuds (5)

ON

On clicking 'execute'

manualTrigger

#1
FU

Function

function

#2
SP

SplitInBatches

splitInBatches

#3
IF

IF

if

#4
SE

Set

set

#5

Comment importer ce workflow

  1. 1Cliquez sur le bouton Télécharger JSON à droite pour enregistrer le fichier du workflow.
  2. 2Ouvrez votre instance n8n. Accédez à Workflows → Nouveau → Importer depuis un fichier.
  3. 3Sélectionnez le fichier split-in-batches-node-currentrunindex-example téléchargé et cliquez sur Importer.
  4. 4Configurez les identifiants pour chaque nœud de service (clés API, OAuth, etc.).
  5. 5Cliquez sur Tester le workflow pour vérifier que tout fonctionne, puis activez-le.

Ou collez directement dans n8n → Importer depuis JSON :

{ "name": "Split In Batches node currentRunIndex example", "nodes": [...], ...}

Intégrations

functionifmanualtriggersetsplitinbatches

Obtenir ce workflow

Téléchargez et importez en un clic

Télécharger JSONVoir sur n8n.io
Nœuds5
Complexitélow
Déclencheurtrigger
Vues2,768
CatégorieMiscellaneous

Créé par

Harshil Agrawal

Harshil Agrawal

@harshil1712

Tags

functionifmanualtriggersetsplitinbatches

Nouveau sur n8n ?

n8n est un outil d'automatisation de workflows gratuit et open-source. Hébergez-le vous-même ou utilisez la version cloud.

Obtenir n8n gratuitement →

Related Miscellaneous Workflows