Posted: Mon Apr 30, 2012 6:19 am Post subject: New Message defintion from two messages
Knight
Joined: 25 Aug 2006 Posts: 589
I have 2 messages. One described by a COBOL copy book and one described by a XML Schema. I have created a message set MYMSG.mset with two message defintion files COBOL_MSG.msxd and XML_MSG.msxd. Each has the message COBOL_MSG and XML_MSG inside it.
I now need to model a new message (New_MSG) which is almost the two messages (COBOL_MSG and XML_MSG) appeneded together (only one or two fields from each one not being used). When I use the option create message definition file from COBOL or Schema, a new message defintion file is always created. All I need is just a new message making up of Types from the original two msxd.
If I have all the Types inside one of the existing msxd, I can create the new message from the types
But I cann ot find a way to copy the types from one msxd to another. Is that the right way to do this ? If not what should be the right way ?
The info center talks about "Linking from one message definition file to another" http://127.0.0.1:53644/help/index.jsp. But it does not say what I can expect after that. I did the include because my XML_MSG.msxd has name space and COBOL_MSG.msxd has no name space. I am using XML_MSG.msxd as my target (i.e. specify the include in XML_MSG.msxd).
I then try to create elements for my NEW_MSG. I expect that I can specify types from COBOL_MSG.msxd as the type for the new local element. But I cannot get it listed under the Type drop down.
The important thing to remember is this: a message set is just a collection of xsd files that happen to have the extension '.mxsd'. Message definition files are linked together in the same way as any other xsd - using xs:import and xs:include directives. So your second post is on exactly the right lines - you need to import or include the (m)xsds that contain the library types.
No idea why you are not seeing the included types listed in the Type dropdown. I assume that they are *global* types in the included xsd ( because if not, that would explain your problem).
btw, when you include ( rather than import ) a no-target-namespace xsd into a namespaced xsd, you will get the 'chameleon' effect. The global definitions in the included xsd will take on the namespace of the host xsd. You probably found that out already.
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