MQ Series Invoke DataStage Job.

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Interesting. Learn something new every day. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
gxhpainter
Premium Member
Premium Member
Posts: 28
Joined: Tue Jul 01, 2008 9:23 am

Read message and continue to wait for new message.

Post by gxhpainter »

Thanks for help,

I can make the job run endlessly till a message arrives.

But I wanted job to run 24/ 7 and when the message arrive in the queue read the message and write to staging file and again continue running state for the next message. It goes on in loop 24 /7.

What are configuration need for MQ Stage to achieve this?

Rgds,
Chakradhar.
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Do you want the Job to terminate after each message? ie...receive a row, write to a flat file, terminate, and then re-start again? If you were receiving very few messages, you could do this simply by having a limit of one row before termination in the stage. After one row is received and then written somewhere, the job will terminate...... use an after job subroutine or other technique to just launch it again. But why terminate the job? Is it just so that you can get access to the flat file? Perhaps you can consider using an rdbms table instead, and make your commit equal to 1 --- then you'll have complete access to the transformed data immediately after it is written.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
gxhpainter
Premium Member
Premium Member
Posts: 28
Joined: Tue Jul 01, 2008 9:23 am

Post by gxhpainter »

No , I don't want to terminate the job. I want to read message from queue and write message to DB Table. job should continue to be in running state.

Rgds,
Chakradhar.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Then an always-running job that does exactly that would seem to me to be exactly what you require.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
gxhpainter
Premium Member
Premium Member
Posts: 28
Joined: Tue Jul 01, 2008 9:23 am

Resolution steps and details for MQ Series Queues.

Post by gxhpainter »

To conclude

Setting at MQ Series Stage
Wait Time : -1
Message Limit : 99999989
End of Data Message : 0

This settings will read the messages for ever and job will be in running state and waiting for the message to arrive.

Use a Database Stage, so that message will be written in the DB as soon as it is delivered and have commit rate as 1.

this is best settings for the quick turnaround.

Thanks for the all the input and it is resolved.

rgds,
Chakradhar.
Post Reply