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 but not xmlns

Post new topic  Reply to topic
 xmlns but not xmlns « View previous topic :: View next topic » 
Author Message
madi
PostPosted: Thu Sep 18, 2008 10:45 am    Post subject: xmlns but not xmlns Reply with quote

Chevalier

Joined: 17 Jan 2006
Posts: 475

How to create

Code:
<GenericMessage xmlns="http://www.something.com/Any">
  <MessageType>SIR-SBL-INVOICE</MessageType>
  <SourceApplication></SourceApplication>
  <SiebelMessage xmlns="http://www.something.com/xml/something" MessageId="" MessageType="" IntObjectName="">
    <ListOfJciIoEdiJciVendorInvoice>


It says

Code:
 Element must have a namespace specified if there is a default namespace in scope.   

Whilst writing the XMLNS message, element 'GenericMessage' was found to be in scope of a default namespace, but this element does not have a namespace defined.   

This error can occur if the NamespaceDecl correlation name has been used to create a default namespace for a parent element, and a child element has been created that does not have a namespace. If you have defined a default namespace in your output message tree, then all elements that are in scope of this default namespace must be defined to be in a namespace. Modify the output message tree so that element 'GenericMessage' is defined to be in a namespace. If element 'GenericMessage' belongs to the default namespace, then this element needs to be created in the default namespace. 


How can I get around this??

--madi
_________________
IBM Certified Solutions Developer - WMB 6.0
Back to top
View user's profile Send private message
broker_new
PostPosted: Thu Sep 18, 2008 11:49 am    Post subject: Reply with quote

Yatiri

Joined: 30 Nov 2006
Posts: 614
Location: Washington DC

I have a very very similar requirement long time back and jeeth_m helped me to get out of that issue..

All you need to do is .
DECLARE mySoapNS NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/';
DECLARE xsd NAMESPACE 'http://staples.com/xsd';
DECLARE soap NAMESPACE 'http://schemas.xmlsoap.org/soap/envelope/';
DECLARE cert NAMESPACE 'http://staples.com/certify';
DECLARE JME NAMESPACE 'http://staples.com/certify/UserAdmin';

SET OutputRoot.XMLNS.mySoapNS:Envelope.(XML.NamespaceDecl)xmlns:"soap" = 'http://schemas.xmlsoap.org/soap/envelope/';
SET OutputRoot.XMLNS.mySoapNS:Envelope.(XML.NamespaceDecl)xmlns:"cert" = 'http://staples.com/certify';
SET OutputRoot.XMLNS.mySoapNS:Envelope.(XML.NamespaceDecl)xmlns:"xsd" = 'http://ibm.com/xsd';

--Default namespace

SET OutputRoot.XMLNS.mySoapNS:Envelope.soap:Body.JME:Information.(XML.NamespaceDecl)xmlns = 'http://staples.com/certify/UserAdmin';
SET OutputRoot.XMLNS.mySoapNS:Envelope.soap:Body.JME:Information.JME:UserId = '34566775';
SET OutputRoot.Properties.MessageDomain = 'XMLNS';

RETURN TRUE;
END;
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Sep 18, 2008 11:56 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

The error message seems very clear to me. What part of it did you find confusing?
Back to top
View user's profile Send private message
madi
PostPosted: Fri Sep 19, 2008 8:29 am    Post subject: Reply with quote

Chevalier

Joined: 17 Jan 2006
Posts: 475

thx broker_new
_________________
IBM Certified Solutions Developer - WMB 6.0
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 but not xmlns
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.