Author |
Message
|
Laurens |
Posted: Fri Jun 21, 2013 5:10 am Post subject: MRM Message set using xsd:datetime |
|
|
Apprentice
Joined: 01 Oct 2009 Posts: 35
|
Hi all ,
I work with a message set with a field having xsd:datetime type.
if I look at the XSD definition of datetime the following patterns (amongst others ) should be accepted :
2012-11-14T00:00:00
2012-11-14T00:00:00Z
I am able to set the broker to accept either of them (using the DateTimeSettigns) but not to accept both of them.
Unfortunately I get files that have both formats in it ; those files are correct according the specifiications but the MRM message set fails .
Any setting I am missing ?
Kind regards
Laurens |
|
Back to top |
|
 |
kimbert |
Posted: Fri Jun 21, 2013 6:11 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Which version of message broker?
What is your input format? ( XML / other )? |
|
Back to top |
|
 |
Laurens |
Posted: Fri Jun 21, 2013 6:14 am Post subject: |
|
|
Apprentice
Joined: 01 Oct 2009 Posts: 35
|
Found the solution :
I added the restriction : [^:Z] in the patterns . |
|
Back to top |
|
 |
Laurens |
Posted: Mon Jun 24, 2013 12:26 am Post subject: |
|
|
Apprentice
Joined: 01 Oct 2009 Posts: 35
|
I answered to fast my own question.
Still having the issue .
The version of the broker is 7.0 and the input is CSV some with date
"2013-06-12T00:00:00+01:00"
"2013-06-12T00:00:00Z"
"2013-06-12T00:00:00"
All perfectly legal dates , but not according to MRM when I validate against it. |
|
Back to top |
|
 |
kimbert |
Posted: Mon Jun 24, 2013 3:48 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Quote: |
if I look at the XSD definition of datetime the following patterns (amongst others ) should be accepted : |
Correct...
Quote: |
The version of the broker is 7.0 and the input is CSV |
...but MRM physical formats are not restricted to the formats supported by the XSD language. If that was true, then it would not be possible for the MRM domain to support binary date/time formats.
The MRM parser supports a wide variety of text calendar formats. See this topic: http://publib.boulder.ibm.com/infocenter/wmbhelp/v7r0m0/topic/com.ibm.etools.mft.doc/ad09291_.htm
If you need to support a range of different formats using a single pattern then the 'I' format is probably what you need ( so set the dateTime pattern to the single character 'I' ). |
|
Back to top |
|
 |
Laurens |
Posted: Tue Jun 25, 2013 12:54 am Post subject: |
|
|
Apprentice
Joined: 01 Oct 2009 Posts: 35
|
Thank you !
Settign at the 'datetime values' , 'use default datetime value'
the string
Iyyyy-MM-dd'T'HH:mm:ssZZZ
works indeed perfectly.
I'm a happy man!
Kind regards
Laurens |
|
Back to top |
|
 |
kimbert |
Posted: Tue Jun 25, 2013 1:38 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
I think you just need the single character 'I'. |
|
Back to top |
|
 |
|