| Author | 
		  Message
		 | 
		
		  | fde | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 1:37 am    Post subject: MRM xml date pattern | 
				     | 
			   
			 
		   | 
		
		
		   Acolyte
 
 Joined: 05 Jul 2007 Posts: 65
  
  | 
		  
		    
			  
				Hello, 
 
hopefully you can help me out with some datetime patterns again.
 
 
I want to parse the date "2000-01-01+02:00" in the MRM domain using XML as physical format. This is a valid xsd:date.
 
 
Pattern: I
 
Message: Unable to convert passed datetime string to an allowable I or T format.
 
 
Pattern: yyyy-MM-ddZZZ
 
Message: The value '2000-01-01T00:00:00.000+02:00' does not conform to the DateTime type as denoted by template ''CCYY-MM-DD''.
 
- I used the values above, something happens here with my inputstring and my pattern. 
 
 
Pattern: yyyy-MM-dd'T'HH:mm:ss.SSSZZZ
 
Message: Unable to parse value '2000-01-01+02:00' using format string 'yyyy-MM-dd'T'HH:mm:ss.SSSZZZ'.
 
- I anticipate behavior from the previous test. This time it behaves different. _________________ Global warming is an unintentional side effect of SOA's hotness.
 
-- http://soafacts.com/
 
a business integration methodology | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fjb_saper | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 2:51 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Grand High Poobah
 
 Joined: 18 Nov 2003 Posts: 20768 Location: LI,NY 
  | 
		  
		    
			  
				Looks like you are getting confused with your types:
 
Date type and datetime types are completely different.
 
date type represents a date. Datetime type represents a timestamp.
 
Have fun   _________________ MQ & Broker admin | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fde | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 3:08 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Acolyte
 
 Joined: 05 Jul 2007 Posts: 65
  
  | 
		  
		    
			  
				Yes, I wrote datetime meaning date for some occurences.
 
To clearify, I want to parse the date "2000-01-01+02:00", which is a valid date although it contains a timezone.
 
I am refering to http://books.xmlschemata.org/relaxng/ch19-77041.html which lists "2000-01-01+02:00" as a valid date example.
 
 
The matching date pattern in MRM xml should be yyyy-MM-ddZZZ accourding to http://publib.boulder.ibm.com/infocenter/wmbhelp/v6r1m0/index.jsp. Using this pattern I get the errormessage:
 
The value '2000-01-01T00:00:00.000+02:00' does not conform to the DateTime type as denoted by template ''CCYY-MM-DD''. 
 
 
There is something strange with that error message.
 
 
First, I used a different input data, 2000-01-01+02:00 instead of 2000-01-01T00:00:00.000+02:00.
 
Second I specified a different pattern, yyyy-MM-ddZZZ instead of CCYY-MM-DD.
 
Third, the basetype for that field is xsd:date instead of DateTime. _________________ Global warming is an unintentional side effect of SOA's hotness.
 
-- http://soafacts.com/
 
a business integration methodology | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fjb_saper | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 3:16 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Grand High Poobah
 
 Joined: 18 Nov 2003 Posts: 20768 Location: LI,NY 
  | 
		  
		    
			  
				Check the message set and verify whether the date / time strict flag is set.
 
Try and check how it works when the flag is set. Try and check how it works when the flag is cleared.    _________________ MQ & Broker admin | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fde | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 3:27 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Acolyte
 
 Joined: 05 Jul 2007 Posts: 65
  
  | 
		  
		    
			  
				Unchecking strict datetime checking, i got the exact same errormessage as above. 
 
Imo, strict checking refers to the date containing no invalid values like a month or day of 40, which should be no problem with my testcase. _________________ Global warming is an unintentional side effect of SOA's hotness.
 
-- http://soafacts.com/
 
a business integration methodology | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fjb_saper | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 3:36 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		    Grand High Poobah
 
 Joined: 18 Nov 2003 Posts: 20768 Location: LI,NY 
  | 
		  
		    
			  
				
   
	| fde wrote: | 
   
  
	Unchecking strict datetime checking, i got the exact same errormessage as above. 
 
Imo, strict checking refers to the date containing no invalid values like a month or day of 40, which should be no problem with my testcase. | 
   
 
 
Wow you're real fast. You changed, deployed and checked in a very short time...
 
 
Strict checking of date time has little to do with date time validation. It has however to do with date / time datetime format enforcing. At least that has been my experience.
 
 
Have fun   _________________ MQ & Broker admin | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fde | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 4:01 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Acolyte
 
 Joined: 05 Jul 2007 Posts: 65
  
  | 
		  
		    
			  
				I already opened the message set editor, the bar to update and soapui for the test. Since you guys are so fast, i refreshed my thread eagerly.
 
Despite some very basic questions, I had a lot of practices with broker development recently.
 
 
Regarding a pattern for MRM xml, I was a little bit disapointed to have to specify a pattern for a common xsd:date string like "2000-01-01+02:00".
 
The generic parsing using I or T (http://publib.boulder.ibm.com/infocenter/wmbhelp/v6r1m0/topic/com.ibm.etools.mft.doc/ad09291_.htm) looked like it could work for me, unfortunately, my datestring doesnt conform to the mentioned ISO ISO8601.
 
 
This leads to specifing a pattern for my date, with the downside of having to use that pattern instead of all forms of xsd:date. 
 
 
   
	| Code: | 
   
  
	
 
2000-01-01+02:00
 
yyyy-MM-ddZZZ
 
 | 
   
 
 
 
Using the pattern and the string above leads to the errormessage which i cannot fully understand due to the mismatches from my second post.
 
 
Is the date pattern wrong somehow? _________________ Global warming is an unintentional side effect of SOA's hotness.
 
-- http://soafacts.com/
 
a business integration methodology | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | fde | 
		  
		    
			  
				 Posted: Wed Apr 29, 2009 7:21 am    Post subject:  | 
				     | 
			   
			 
		   | 
		
		
		   Acolyte
 
 Joined: 05 Jul 2007 Posts: 65
  
  | 
		  
		    
			  
				I encountered something disturbing. 
 
After rolling back my message set to the default date pattern yyyy-MM-dd I errorously issued my testcase with the suspicious date string 2000-01-01+02:00.
 
The string is parsed correctly with the default pattern. The only difference between my initial setup and the rolledback one is, the strict datetime checking being disabled now.
 
 
I have to investigate further what happend but for know, I am able to parse my date string.
 
 
Thanks for the tip with the strict datetime checking, I suppose that did the trick. _________________ Global warming is an unintentional side effect of SOA's hotness.
 
-- http://soafacts.com/
 
a business integration methodology | 
			   
			 
		   | 
		
		
		  | Back to top | 
		  
		  	
		   | 
		
		
		    | 
		
		
		  | 
		    
		   |