I needed to create two queues with one disptacher reframework logic. Please explain how to do it

Hello Team,

I have a requirement where I need to two queues with one disptacher reframework logic. Please explain how to do it

Any suggestions would be helpful?

Thanks,
Nawaz.

The two queues which needss to be created comes from two excel sheets. Please provide suggestions. Thanks

Hi @mohammed_nawazuddin1

You can use the same Dispatcher REFramework for both queues.

  • Read the Excel file
  • Loop through the sheets
  • Based on the sheet name, decide which queue to use
If SheetName = "Sheet1" Then
   QueueName = "Queue1"
Else
   QueueName = "Queue2"
End If

Then use the same Add Queue Item activity and pass the QueueName variable dynamically.

  • Read Sheet1 → Add records to Queue1
  • Read Sheet2 → Add records to Queue2

By the end of the loop, all records from both sheets will be added to their respective queues.

Let me know if you need any further help.

@mohammed_nawazuddin1

You have two worksheets, for that two sheets data you need to add it in the queue, Here if your excel only having two sheets then

  • get the sheets count. or add a loop condition
  • in that loop, use a condition to add the records in queue. Let say if name of the sheet is sheet 1, then add the data in queue 1, if name of the sheet is sheet2 then add the data in queue 2.
  • by ending of the loop you can see all the records will be added in queues.

Hope it helps!

Hi @mohammed_nawazuddin1

Yes, you can use one Dispatcher for two queues. Just read both Excel files separately, then push data from the first Excel to Queue A and from the second Excel to Queue B using Add Queue Item. A better way is to add a “QueueName” column in your Excel, merge both data tables, and use one loop to push items dynamically based on that column.

Can you share sample as there are many Arguements like Get Transaction Data, Out_Transaction_Item and io_dt_Transactiondata how to use them. Any suggestions would be helpful. Thanks

Hi @mohammed_nawazuddin1

In Dispatcher REFramework, first in the Init state you read your Excel file and store all the data in io_dt_TransactionData, which holds the complete dataset. Then in the Get Transaction Data state, the framework picks one row at a time from this data and stores it in out_TransactionItem, which represents the current item being processed. After that, in the Process state, you use this current row to perform actions like adding it to a queue. The framework automatically loops through all rows one by one until all data is processed.

In Dispatcher REFramework, you mainly need to work inside the Get Transaction Data state.

  • Read Sheet1 data into dt_Sheet1
  • Read Sheet2 data into dt_Sheet2
  • Loop through both sheets separately
  • Set Queue Name dynamically based on sheet name
If SheetName = "Sheet1" Then
   QueueName = "Queue1"
Else
   QueueName = "Queue2"
End If

Then use the same Add Queue Item activity:

QueueName = QueueName
ItemInformation = CurrentRow
  • io_dt_TransactionData
    → Stores Excel/transaction data DataTable

  • out_Transaction_Item
    → Current transaction/row being processed

  • Get Transaction Data
    → Used to fetch next transaction item from DataTable

In Dispatcher scenario, you usually:

  • read Excel data
  • loop rows
  • add queue items

So you may not need full transaction handling logic like Performer REFramework.

Hi @MohammedShabbir,

You can handle two queues in a single Dispatcher REFramework by reading multiple sheets or datasets and dynamically assigning the queue name during processing.

Basic Approach

  • Read Sheet1 into dt_Sheet1
  • Read Sheet2 into dt_Sheet2

Then inside Get Transaction Data or Process logic:

If SheetName = "Sheet1" Then    QueueName = "Queue1"Else    QueueName = "Queue2"End If

Use the same Add Queue Item activity:

QueueName = QueueNameItemInformation = CurrentRow

REFramework Variables

  • io_dt_TransactionData
    → Stores complete Excel/DataTable data
  • out_Transaction_Item
    → Holds current row/item being processed
  • Get Transaction Data
    → Fetches next transaction item row by row

Flow

  1. Read Excel data in Init state
  2. Store data in DataTables
  3. Loop through rows one by one
  4. Decide queue dynamically
  5. Add item to corresponding queue

This way, one Dispatcher can push transactions into multiple queues using the same REFramework logic.