Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

A looping map where input = output 2

Status
Not open for further replies.

MrStiffler

Programmer
Jan 7, 2004
25
0
0
CH
I have a situation where i need to count information about message processing. So i take the exist Input A and add the information/counters form the new Input B.
Target ist go get an updatet new file A. This is like a loop proces where i add digits to the counting File A.

Now Mercator seems not to be not able to read a input and write to the same source as output.
The only way to handle this is, to use another map whitch read that output and write it 1 to 1 to the input file again.
Do somebody had a similar problem ? It would be much easier and faster to have only one map looping.
thank you
 
If you are updating a fixed length field in your input file then you can use GETANDSET to update the file directly otherwise you need the intermediate file.
 
What error do you get? We have quite a few maps that read and write to the same file, although they are all run maps and don't run directly under the Event Server.
 
There is no error. But the map can only run 1 time !
The input ist triggered, this mean it has a Source Event defined !
I think that the output writing process blocks the trigger of the input ! So it ist not possible for the map itselfs to automaical rerun and loop x times

The unique input from a MQ Series Queue is flagged as Source Event. So if the next message in the queue is ready to get mapped, i think the input A is still blocked by the map runed before. Therefor the map don't run a second time !

I tried to fix the problem with a Delay on the Map in the Flow Designer and i tried with a Retriy on the input A Card!
But it don't work yet.
I don't know if this reason is the right one!
 
As you are not triggering on the source file you are writing to, I can't see it being any different to any other target you might write to. The only thing is that all your maps will single thread because they all need to write to read and write to the same file. Have you checked the Management Console (if you are using version 6.7) to see what resources maps are waiting for?
 
So, your I/O file is the trigger file or is the 'unique input from a MQ Series Queue' the trigger? both?

Are you attempting to multithread?

eyetry

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top