Hi all,
I have a simple piece of code that sends a single message to a service, which is then "connected" to a queue, and this queue has an associated stored procedure.
A code example:
SET @ConversationHandle = NEWID() BEGIN DIALOG @ConversationHandle FROM SERVICE [InitiatorService] TO SERVICE ReceiverService WITH ENCRYPTION = OFF, LIFETIME = 3600; SEND ON CONVERSATION @ConversationHandle MESSAGE TYPE [DEFAULT] ('921834729384'); END CONVERSATION @ConversationHandle
So what this code does is sending the number 921834729384 into the service.
I need to execute something like this for several distinct ID's, and I don't want to send them all at a time. Currently I'm running this inside a cursor, and I'd like to find a way of sending all ID's in parallel into the queue (respecting a predefined order) but avoiding something like a cursor or a cycle.
Is there any workaround?
Thank you.