I need help for the below requirement. Tried searching the forum, could not find answer, so posting it here.
My COBOL cics program reads data from an MQ and based on reference number present on the MQ it needs to route the message to one of the 5 output MQ's. The src-ref-no (reference number) is X(20) and it can contain numeric as well as alphanumeric and special characters like '-' etc;
I need to define the range on this src-ref-no to distribute the incoming traffic to the 5 different output mq's.
Each time the the program gets the same src-ref-no again and again it should route the message to the same output MQ as it was sent earlier. Something like :
if src-ref-no > range-1
go to mq-1
else if src-ref-no > range-2
go to mq-2.
how to define the range on alphanumeric items ? I can have the range hardcoded in the program or read from a db2 table.
I can rip off the special chars and apply a uniform range on the alphanumeric field too.
You need to clear about the term Range. For me it seems the requirements are not cleared.
If you get abc1150235454 then what would you like to do? What range you want?
As you said, you can predefine the ranges in DB2 and then select the Queue name based on input src-ref-no value.