Search code examples
sql-serverssissql-server-2014msmq

How to configure MSMQ Task to send message to different MSMQ based on variable in SSIS?


I have a column inside the database that contains messages. These messages need to go to a different MSMQ based on the message ID.

How do I configure the MSMQ Task inside SSIS to take a different connection string based on the message ID? Is this even possible?


Solution

  • Looks like one way is to write a Script Task which will take the connection string as a parameter and send it out to the specified queue. Use this task inside a For Each Loop to get the connection string for each message and send them out one at a time.