| Author | 
		  Message
		 | 
		
		  | catwood2 | 
		  
		    
			  
				 Posted: Wed Jun 09, 2004 2:48 pm    Post subject: MRM Validation Error | 
				     | 
			   
			 
		   | 
		
		
		   Centurion
 
 Joined: 17 May 2002 Posts: 108
  
  | 
		  
		    
			  
				Hi All,
 
I'm running WMQI 2.1 CSD6.
 
 
I have imported a schema into the MRM and have set validation property on a compute node. On write to output, I am getting a validation failure with the complaint that an element with minoccurs1 does not exist in the message tree. A trace before the Output node shows that the element is present. I have re-imported to mrm, tried renaming the element in question - still getting this validation error. All other validation (including element with minoccurs1 working as expected).
 
Pointers much appreciated!
 
 
Details (trace error, message tree prior to output, original schema):
 
 
   
	| Quote: | 
   
  
	Trace shows this error:
 
2004-06-09 21:35:49.465934     2057   ParserException  BIP5286E: Message Translation Inter
 
face Writing Errors have occurred:
 
                                       Message Set Name  : 'CSCUSDNDC001_CRETIK10'
 
                                       Message Set Level : '1'
 
                                       Message Format    : 'XML'
 
                                       Message Type Path : ''
 
                                       Review further error messages for an indication to
 
the cause of the errors.
 
2004-06-09 21:35:49.466033     2057   ParserException  BIP5374E: Message Validation failur
 
e. An element, that has been deemed complete, does not meet the minOccurs constraint.
 
                                       Element, Message_ANON^Comment, has 0 instances on t
 
he logical tree, but has been defined or qualified with a minOccurs Constraint of 1 within
 
 it's parent type/element Message_ANON of index 1. | 
   
 
 
 
   
	| Quote: | 
   
  
	Message Root from Trace node output before MQOutput:
 
 (0x1000021)MRM        = (
 
   (0x300000B)Source_Appl            = 'CSCPRODAB001'
 
   (0x300000B)Target_Appl            = 'CSCUSDNDC001'
 
   (0x300000B)Message_Type           = 'CRETIK'
 
   (0x300000B)Message_Version        = '1.0'
 
   (0x300000B)Comment               = 'test for EAI'
 
   (0x300000B)ProviderPriority       = 5
 
   (0x300000B)RequesterSeverity      = 0
 
   (0x300000B)CurrentState           = 'OP'
 
   (0x300000B)TransactionDateTime    = 1086819489
 
   (0x1000013)Customer               = (
 
     (0x300000B)LastName  = 'Dankovits, Kris3'
 
     (0x300000B)zPhone    = '908-665-6328'
 
     (0x300000B)zUniqueID = 'dankovitsk'
 
   )
 
   (0x1000013)Agent                  = (
 
     (0x300000B)LastName  = 'Flint'
 
     (0x300000B)zUniqueID = 'flinta'
 
   )
 
   (0x300000B)zSTC                   = 'DAB.Ber.Otbf.Srvr.Swcb.Bolt3'
 
   (0x300000B)RequesterID            = 'HD0000000227713'
 
   (0x300000B)zExchangeFlagIndicator = '2'
 
 ) | 
   
 
 
 
   
	| Quote: | 
   
  
	Imported Schema:
 
<?xml version="1.0" encoding="UTF-8"?>
 
<xs:schema xmlns:xs="http://www.w3schools.com" elementFormDefault="qualified">
 
 
  <xs:simpleType name="State">
 
  <xs:restriction base="string">
 
  <enumeration value="ACK"/> 
 
  <enumeration value="AS"/> 
 
  <enumeration value="BY"/>
 
  <enumeration value="CLO"/>
 
  <enumeration value="CN"/>
 
  <enumeration value="FR"/>
 
  <enumeration value="IW"/>
 
  <enumeration value="MO"/>
 
  <enumeration value="OP"/>
 
  <enumeration value="RA"/> 
 
  <enumeration value="RJ"/> 
 
  <enumeration value="RL"/> 
 
  <enumeration value="RP"/> 
 
  <enumeration value="SC"/>
 
  </xs:restriction>
 
  </xs:simpleType>
 
 
  <xs:simpleType name="Priority">
 
  <xs:restriction base="integer">
 
  <xs:minInclusive value="1"/>
 
  <xs:maxInclusive value="5"/>
 
  </xs:restriction>
 
  </xs:simpleType>
 
 
  <xs:simpleType name="Severity">
 
  <xs:restriction base="integer">
 
  <enumeration value="0"/> 
 
  <enumeration value="5"/> 
 
  </xs:restriction>
 
  </xs:simpleType>
 
 
  <xs:complexType name="Properties">
 
  <xs:all>
 
  <xs:element name="Sequence" type="integer"/>
 
  <xs:element name="Label" type="string"/>
 
  <xs:element name="Value" type="string"/>
 
  </xs:all>
 
  </xs:complexType>
 
 
 <xs:element name="Message">  
 
 <xs:complexType>
 
 <xs:all>
 
 
  <xs:element name="Source_Appl" type="string" minOccurs="1"/>
 
  <xs:element name="Target_Appl" type="string" minOccurs="1"/>
 
  <xs:element name="Message_Type" type="string" minOccurs="1"/>
 
  <xs:element name="Message_Version" type="string" minOccurs="1"/>
 
  <xs:element name="RequesterID" type="string" minOccurs="1"/> 
 
  <xs:element name="zExchangeFlagIndicator" type="string" minOccurs="1"/>
 
  <xs:element name="TransactionDateTime" type="integer" minOccurs="1"/>
 
  <xs:element name="zSTC" type="string" minOccurs="1"/>
 
  <xs:element name="ActionLog" type="string" minOccurs="0"/>
 
  <xs:element name="zActivityDateTime" type="integer" minOccurs="0"/>
 
  <xs:element name="Comment" type="string" minOccurs="1"/>
 
  <xs:element name="CurrentState" type="State" minOccurs="0"/>
 
  <xs:element name="ProviderPriority" type="Priority" minOccurs="0"/>
 
  <xs:element name="RequesterSeverity" type="Severity" minOccurs="0"/>
 
  <xs:element name="zCOProperties" type="Properties" minOccurs="0"/>
 
  <xs:element name="zCRProperties" type="Properties" minOccurs="0"/>
 
 
  <xs:element name="Agent">
 
  <xs:complexType>
 
  <xs:all>
 
  <xs:element name="zUniqueID" type="string" minOccurs="1"/>
 
  <xs:element name="FirstName" type="string" minOccurs="0"/>
 
  <xs:element name="MiddleName" type="string" minOccurs="0"/>
 
  <xs:element name="LastName" type="string" minOccurs="1"/>
 
  </xs:all>
 
  </xs:complexType>
 
  </xs:element>
 
 
  <xs:element name="Customer">
 
  <xs:complexType>
 
  <xs:all>
 
  <xs:element name="zUniqueID" type="string" minOccurs="1"/>
 
  <xs:element name="FirstName" type="string" minOccurs="0"/>
 
  <xs:element name="MiddleName" type="string" minOccurs="0"/>
 
  <xs:element name="LastName" type="string" minOccurs="1"/>
 
  <xs:element name="zPhone" type="string" minOccurs="1"/>
 
  </xs:all>
 
  </xs:complexType>
 
  </xs:element>
 
 
  <xs:element name="Asset">
 
  <xs:complexType>
 
  <xs:all>
 
  <xs:element name="AssetTag" type="string" minOccurs="0"/>
 
  <xs:element name="AssetModel" type="string" minOccurs="0"/>
 
  <xs:element name="AssetManufacturer" type="string" minOccurs="0"/>
 
  <xs:element name="SerialNumber" type="string" minOccurs="0"/>
 
  <xs:element name="Division" type="string" minOccurs="0"/>
 
  <xs:element name="Plant" type="string" minOccurs="0"/>
 
  <xs:element name="Building" type="string" minOccurs="0"/>
 
  <xs:element name="Floor" type="string" minOccurs="0"/>
 
  <xs:element name="Room" type="string" minOccurs="0"/>
 
  <xs:element name="Desk" type="string" minOccurs="0"/>
 
  </xs:all>
 
 
  </xs:complexType>
 
  </xs:element>
 
 
 
 </xs:all>
 
 </xs:complexType>
 
 </xs:element>
 
</xs:schema> | 
   
 
 | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | kirani | 
		  
		    
			  
				 Posted: Wed Jun 09, 2004 10:23 pm    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Jedi Knight
 
 Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA 
  | 
		  
		    
			  
				If you in your trace output, not all elements with minoccurs=1 are present. For example, zSTC element is not there in your trace output. _________________ Kiran
 
 
 
IBM Cert. Solution Designer & System Administrator - WBIMB V5
 
IBM Cert. Solutions Expert - WMQI
 
IBM Cert. Specialist - WMQI, MQSeries
 
IBM Cert. Developer - MQSeries
 
 
 | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | catwood2 | 
		  
		    
			  
				 Posted: Thu Jun 10, 2004 6:18 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Centurion
 
 Joined: 17 May 2002 Posts: 108
  
  | 
		  
		    
			  
				Thanks for looking at this kirani. Actually zSTC is there:
 
   
	| Quote: | 
   
  
	| (0x300000B)zSTC = 'DAB.Ber.Otbf.Srvr.Swcb.Bolt3'  | 
   
 
 
 
thx | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | kirani | 
		  
		    
			  
				 Posted: Thu Jun 10, 2004 10:35 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Jedi Knight
 
 Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA 
  | 
		  
		    
			  
				It's there but the order is incorrect. right? _________________ Kiran
 
 
 
IBM Cert. Solution Designer & System Administrator - WBIMB V5
 
IBM Cert. Solutions Expert - WMQI
 
IBM Cert. Specialist - WMQI, MQSeries
 
IBM Cert. Developer - MQSeries
 
 
 | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | catwood2 | 
		  
		    
			  
				 Posted: Thu Jun 10, 2004 11:35 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Centurion
 
 Joined: 17 May 2002 Posts: 108
  
  | 
		  
		    
			  
				I understand the 'xs:all' indicator to mean the children can appear in any order. 
 
I am testing the other elements 1 by 1:
 
 
If I remove <Source_Appl> I get the following error on validation:
 
   
	| Quote: | 
   
  
	2004-06-10 19:32:20.773830     2077   ParserException  BIP5286E: Message Translation Inter
 
face Writing Errors have occurred:
 
                                Message Set Name  : 'CSCUSDNDC001_CRETIK10'
 
                                       Message Set Level : '1'
 
                                       Message Format    : 'XML'
 
                                       Message Type Path : ''
 
                                       Review further error messages for an indication to the cause of the errors.
 
2004-06-10 19:32:20.773929     2077   ParserException  BIP5374E: Message Validation failure. An element, that has been deemed complete, does not meet the minOccurs constraint.
 
Element, Message^xmlns_xs, has 0 instances on the logical tree, but has been defined or qualified with a minOccurs Constraint of 1 within it'
 
s parent type/element Message_attrs of index 1. | 
   
 
 
 
what is Message^xmlns_xs? I was expecting to see Message.Source_Appl...
 
 
IF I remove zSTC - the minOccurs of 1 is not enforced.
 
 
ANY thoughts/pointers GREATLY appreciated. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | catwood2 | 
		  
		    
			  
				 Posted: Thu Jun 10, 2004 11:41 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Centurion
 
 Joined: 17 May 2002 Posts: 108
  
  | 
		  
		    
			  
				If I remove Agent.zUniqueID....I get what I would expect:
 
2004-06-10 19:37:29.994634     2077   ParserException  BIP5286E: 
   
	| Quote: | 
   
  
	Message Translation Inter
 
face Writing Errors have occurred:
 
                                       Message Set Name  : 'CSCUSDNDC001_CRETIK10'
 
                                       Message Set Level : '1'
 
                                       Message Format    : 'XML'
 
                                       Message Type Path : ''
 
                                       Review further error messages for an indication to
 
the cause of the errors.
 
2004-06-10 19:37:29.994733     2077   ParserException  BIP5374E: Message Validation failur
 
e. An element, that has been deemed complete, does not meet the minOccurs constraint.
 
 Element, Agent_ANON^zUniqueID, has 0 instances on the logical tree, but has been defined or qualified with a minOccurs Constraint of 1 within
 
 it's parent type/element Message_ANON^Agent of index 1.
 
Adjust the minOccurs Constraint downwards and redeploy to the broker or increase the instances of the element in the bitstream or through ESQL. | 
   
 
 | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | catwood2 | 
		  
		    
			  
				 Posted: Thu Jun 10, 2004 1:23 pm    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Centurion
 
 Joined: 17 May 2002 Posts: 108
  
  | 
		  
		    
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | catwood2 | 
		  
		    
			  
				 Posted: Thu Jun 10, 2004 2:52 pm    Post subject: MRM Validation Error - SOLVED | 
				     | 
			   
			 
		   | 
		
		
		   Centurion
 
 Joined: 17 May 2002 Posts: 108
  
  | 
		  
		    
			  
				Ok. Non WMQI familiar Co-Worker pointed something. 
 
These lines in my schema:
 
   
	| Quote: | 
   
  
	| <xs:schema xmlns:xs="http://www.w3schools.com" elementFormDefault="qualified">  | 
   
 
 
 
Is pointing to a location where the schema definition does not reside.
 
 
Change it to:
 
   
	| Quote: | 
   
  
	| <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"> | 
   
 
 
 
Import into new message set - and all working as expected. 
 
 
btw - the tutorials on w3schools are excellent. | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | 
		    
		   |