All Forums Extensibility
RandiPedigo 2 posts Joined 05/12
07 Nov 2014
Queue to Queue

Hi,
 
I was wondering if anybody has or knows where I can find an example of a stored procedure that writes from a queue table in TD to an external queue (say activeMQ) via a stored procedure (JDBC connection). Anything would be helpful!
 
Thanks,
Randi

Raja_KT 1246 posts Joined 07/09
08 Nov 2014

Maybe this can help you:
Kudos to Dieter's stored proc for stats, using queue table. Good reference for push..pop:
http://developer.teradata.com/blog/dnoeth/2012/10/how-to-simplify-your-statistics-collection-with-a-queue-table
For peek it is simple select.
Also like in oracle you can use select ....into ...a variable for processing for pop.
You can use a temp table to populate from a queue table:

INSERT INTO tempTbl

    SELECT AND CONSUME TOP 1 * FROM qTbl;

 

For loading to external MQ, I think you can somehow adjust in your jdbc program. Most of the message queues programs I worked with in the past like Ab Initio continuous flow are slow :).

Did you check with MyBatis? It can be more handy, who knows.
 

Raja K Thaw
My wiki: http://en.wikipedia.org/wiki/User:Kt_raj1
Street Children suffer not by their fault. We can help them if we want.

You must sign in to leave a comment.