|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
removing extra XML elements using MRM? |
« View previous topic :: View next topic » |
Author |
Message
|
vmcgloin |
Posted: Wed Apr 11, 2007 1:24 am Post subject: removing extra XML elements using MRM? |
|
|
Knight
Joined: 04 Apr 2002 Posts: 560 Location: Scotland
|
Hi,
I am doing some complex formatting from an input CWF message to an output XML message - both defined in the MRM. To reformat the message I am adding index fields so that I can merge subtree's dependent on their values, so when I get the output XML it has extra <transaction_index> and <fund_index> fields. As these are not in the message definition I assumed that they would be stripped out, but they are not.
Is there any way I can force this to happen automatically?
I have the option of stepping through the entire message tree (several layers deep and quite big) and removing them, but I'd rather not do that?
The other option is essentially duplicating all of the data to keep my index tree in the LocalEnvironment and writing the output tree without the index, but that does not seem very efficient either.
Any suggestion would be very much appreciated.
Thanks,
Vicky |
|
Back to top |
|
 |
kimbert |
Posted: Wed Apr 11, 2007 2:08 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
The MRM XML serializer will output everything in the message tree, and there is no way to change that.
I followed your previous thread re: the indexes. Maybe the correct solution here is to put only the the indexes into the local environment tree. That will probably complicate your ESQL, because you will have to keep two references in step with one another - one pointing at the input tree and the other pointing at the corresponding index in the environment tree. |
|
Back to top |
|
 |
vmcgloin |
Posted: Wed Apr 11, 2007 2:21 am Post subject: |
|
|
Knight
Joined: 04 Apr 2002 Posts: 560 Location: Scotland
|
OK. Thanks for the quick reply. (Is responding here officially part of your support role? You do a fantastic job!)
I'll have a look and see if I can keep 2 indexes in step, but at the moment I see how I could do that without keeping most of the tree in the local environment too..
I currently have ESQL like this to search for matches.
Code: |
-- Is there an existing transaction with the same details?
SET existingFieldIndex =
THE (SELECT X.transaction_index FROM outputMsgRef.transaction[] AS X
WHERE X.transaction_date = trans.transaction_date
AND X.transaction_amount = trans.transaction_amount
AND X.frequency = trans.frequency
AND X.payer = trans.payer); |
Thanks again,
Vicky |
|
Back to top |
|
 |
kimbert |
Posted: Wed Apr 11, 2007 11:56 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
What support role I'm just a developer who prefers to develop things which are useful to real customers.
I was assuming that you were indexing the source data and then using the indexes in a separate phase of the transformation. Looks like I was wrong  |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|