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 » Xmlns:xsi schemalocation issue

Post new topic  Reply to topic
 Xmlns:xsi schemalocation issue « View previous topic :: View next topic » 
Author Message
mbscott
PostPosted: Thu Mar 15, 2012 12:47 pm    Post subject: Xmlns:xsi schemalocation issue Reply with quote

Novice

Joined: 15 Jul 2011
Posts: 15

Hi,

In my flow i am getting below xml with invalid schema locations, i need to correct it and send to wtx map.

<?xml version="1.0" encoding="UTF-8"?>
<ROOT xmlns:xsi="htt//www.w3.org/2001/XMLSchema-instance" xmlns="http://xml-schemas.yyyy.com/esb/request.xsd" xsi:schemaLocation="htt//xml-schemas.yyyy.com/esb/request.xsd request.xsd>
<REQUEST-INFO>
<REQ-NAME>SOURCE</REQ-NAME>
<REQ-CODE>LOCAL</REQ-CODE>
</REQUEST-INFO>
</ROOT>

in Http:// p. missing

In output i need to correct it. i tried below

CALL CopyEntireMessage();

SET OutputRoot.XMLNSC.ns.ROOT.(XMLNSC.Attribute)xmlns:xsi = 'http://www.w3.org/2001/XMLSchema-instance';
SET OutputRoot.XMLNSC.ns.ROOT.(XMLNSC.Attribute)xsi:schemaLocation = 'http://xml-schemas.yyyy.com/esb/request.xsd request.xsd';

xsi:schemaLocation value getting overrided and xmlns:xsi not overriding more over creating one more xsi attribute.

Please help me on this?
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu Mar 15, 2012 8:05 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

How about using a field reference and changing its fieldvalue?
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
mqsiuser
PostPosted: Fri Mar 16, 2012 12:58 am    Post subject: Reply with quote

Yatiri

Joined: 15 Apr 2008
Posts: 637
Location: Germany

You are using the default namespace ("xmlns"). There has been valuable input here and here.
_________________
Just use REFERENCEs
Back to top
View user's profile Send private message
rekarm01
PostPosted: Fri Mar 16, 2012 1:36 am    Post subject: Re: Xmlns:xsi schemalocation issue Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

mbscott wrote:
Code:
SET OutputRoot.XMLNSC.ns.ROOT.(XMLNSC.Attribute)xmlns:xsi = 'http://www.w3.org/2001/XMLSchema-instance';

Namespace declarations are not attributes.
Back to top
View user's profile Send private message
mqsiuser
PostPosted: Fri Mar 16, 2012 1:45 am    Post subject: Re: Xmlns:xsi schemalocation issue Reply with quote

Yatiri

Joined: 15 Apr 2008
Posts: 637
Location: Germany

rekarm01 wrote:
mbscott wrote:
Code:
SET OutputRoot.XMLNSC.ns.ROOT.(XMLNSC.Attribute)xmlns:xsi = 'http://www.w3.org/2001/XMLSchema-instance';

Namespace declarations are not attributes.

looks similar though

Hmmm... could it be, that the W3C and XMLNSC have different views on that ?
_________________
Just use REFERENCEs
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Mar 16, 2012 4:55 am    Post subject: Re: Xmlns:xsi schemalocation issue Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

mqsiuser wrote:
looks similar though


A car looks similar to a truck (4 wheels, engine, somewhere for the driver to sit) but they're very different things.

mqsiuser wrote:
Hmmm... could it be, that the W3C and XMLNSC have different views on that ?


I'm sure kimbert will be along in a moment to clarify this, possibly quite loudly. AFAIK the XMLNSC parser is fully compliant, and that's where there are different constants for namespace declarations & attributes.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Fri Mar 16, 2012 5:06 am    Post subject: Re: Xmlns:xsi schemalocation issue Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

Vitor wrote:
a truck

You've lived in America too long. How does one spell 'color' again?
Back to top
View user's profile Send private message
mqsiuser
PostPosted: Fri Mar 16, 2012 5:13 am    Post subject: Re: Xmlns:xsi schemalocation issue Reply with quote

Yatiri

Joined: 15 Apr 2008
Posts: 637
Location: Germany

Vitor wrote:
I'm sure kimbert will be along in a moment to clarify this, possibly quite loudly. AFAIK the XMLNSC parser is fully compliant, and that's where there are different constants for namespace declarations & attributes.

A parser needs to work exactly that way. The standard is also ok.... there is nothing to worry about !

The confusion from the OP (and actually I was also once at that point) just comes from this slight difference in terminology... but a parser is a parser and a w3c standard (recommendation) is a w3c recommendation... nothing to worry, just something to have in mind.

And a user trace + the infocenter will perfectly clarify about this.
_________________
Just use REFERENCEs
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Mar 16, 2012 5:50 am    Post subject: Re: Xmlns:xsi schemalocation issue Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

mqjeff wrote:
Vitor wrote:
a truck

You've lived in America too long.


Possibly. I also embrace the influence America has had on worldwide culture and language.

mqjeff wrote:
How does one spell 'color' again?


Correctly.
_________________
Honesty is the best policy.
Insanity is the best defence.
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 » Xmlns:xsi schemalocation issue
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.