ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Mapping empty nodes with attributes

Post new topic  Reply to topic
 Mapping empty nodes with attributes « View previous topic :: View next topic » 
Author Message
ggriffith
PostPosted: Tue Oct 23, 2007 7:25 am    Post subject: Mapping empty nodes with attributes Reply with quote

Acolyte

Joined: 17 Oct 2007
Posts: 67

I've encountered the following problem using the mapping node

With an input of

<A B="xxxx">yyyy</A>

and mapping A to a similar node on the output I get the expected

<A>yyyy</A>

but when the input node A has no value, only an attribute

<A B="xxxx"/>

I get an unexpected result of

<A><B>xxxx</B></A>

Any ideas of how to get the expected <A/> or even no output node before I revert to good old ESQL.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Oct 23, 2007 7:32 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Which domain are you using. If XMLNSC, you may be encountering a known defect.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Oct 23, 2007 7:32 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

What domain?

What mapping expression?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ggriffith
PostPosted: Tue Oct 23, 2007 7:37 am    Post subject: Reply with quote

Acolyte

Joined: 17 Oct 2007
Posts: 67

Correct I'm using the XMLNSC domain.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Oct 23, 2007 7:44 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

It's a known defect. The fix is in v6 FP04.
For more details, search the forum for 'XMLNSC empty'
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Oct 23, 2007 7:54 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

kimbert wrote:
It's a known defect. The fix is in v6 FP04.
For more details, search the forum for 'XMLNSC empty'


You mean FP05. FP04 was withdrawn and additional fixes were incorporated to make it FP05.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
ggriffith
PostPosted: Mon Nov 05, 2007 7:01 am    Post subject: Reply with quote

Acolyte

Joined: 17 Oct 2007
Posts: 67

OK, I've now updgraded to 6.0.0.5 and it's made no difference.
The mapping expression is a straight copy of $source<A> to $target<a>
Back to top
View user's profile Send private message
kimbert
PostPosted: Mon Nov 05, 2007 1:10 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

If you're absolutely sure that XMLNSC is behaving incorrectly, please raise a PMR.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Nov 06, 2007 6:08 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

...and please mention that this is the same problem as PMR 12211,999,866. There is an IFix for FP03.
Back to top
View user's profile Send private message
ggriffith
PostPosted: Tue Nov 06, 2007 6:21 am    Post subject: Reply with quote

Acolyte

Joined: 17 Oct 2007
Posts: 67

Found another post with a similar problem, where Jeff suggested using XMLNS instead. Tried this and it works perfectly.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Nov 06, 2007 7:00 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Note to all readers of this post...

ggriffith needs to get his message flow working, so he has probably made the correct decision. However, the XMLNSC behaviour described above is a defect and it has been fixed. I am going to install FP05 and confirm that it behaves correctly. Every other user who has reported this defect has installed the fix, and found that the problem was cured.

XMLNSC is the preferred XML parser. v6.1 has already put XMLNSC far ahead of XMLNS on both performance and function, and that pattern is going to continue.
Back to top
View user's profile Send private message
ggriffith
PostPosted: Tue Nov 06, 2007 8:57 am    Post subject: Reply with quote

Acolyte

Joined: 17 Oct 2007
Posts: 67

I take it there's no secret extra step required in the FP05 install, in addition to

1. Decompress.
2. Run the wizard.
3. Restart the broker.

please note our MQSIProfile command states that we have upgraded to 6.0.0.5

As everyone else appears to have solved their problems with FP05 it would be good to know why we haven't.

I've noticed that there are varying scenarios of this this problem. If you're going to verify the fix could you duplicate our problem please. ie. mapping node that maps an empty node with attribute to target node.

iheader:OUTLET $source/tns1:Invoice/tns1:ShipTo/tns1:BuyerAssigned

and input of

<?xml version="1.0" encoding="UTF-8"?>
<Invoice xmlns="http://www.eanucc.org/2002/Pay/FoodService/FoodService/UK/EanUcc/Pay"
xmlns:cc="http://www.ean-ucc.org/2002/gsmp/schemas/CoreComponents">
<ShipTo>
<BuyerAssigned scheme="GTIN"></BuyerAssigned>
</ShipTo>
</Invoice>

results in

<NS2:OUTLET>
<scheme>GTIN<scheme>
</NS2:OUTLET>
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Nov 06, 2007 9:06 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

You'll need to open the PMR if you want any official verification of the problem or official confirmation that the fix is not correct.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Mapping empty nodes with attributes
Jump to:  



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
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.