webMethods

webMethods

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  using xs:date in Tamino schema

    Posted Mon May 06, 2002 11:13 PM

    I am having trouble loading data into Tamino after I change an element from xs:string to xs:data

    I want to sort on the ‘date’ field

    Here is my schema

    <?xml version = "1.0" encoding = "UTF-8"?>
    <xs:schema xmlns:xs = “XML Schema” xmlns:tsd = “http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition”>
    xs:annotation
    xs:appinfo
    <tsd:schemaInfo name = “email”>
    <tsd:collection name = “stuff”></tsd:collection>
    <tsd:doctype name = “email”>
    tsd:logical
    tsd:contentclosed</tsd:content>
    </tsd:logical>
    </tsd:doctype>
    </tsd:schemaInfo>
    </xs:appinfo>
    </xs:annotation>
    <xs:element name = “email”>
    xs:complexType
    xs:sequence
    <xs:element ref = “subject”></xs:element>
    <xs:element ref = “date”></xs:element>
    <xs:element ref = “to”></xs:element>
    <xs:element ref = “from”></xs:element>
    <xs:element ref = “body”></xs:element>
    </xs:sequence>
    </xs:complexType>
    </xs:element>
    <xs:element name = “subject” type = “xs:string”></xs:element>
    <xs:element name = “date” type = “xs:date” default = “2002-01-01”></xs:element>
    <xs:element name = “to” type = “xs:string”></xs:element>
    <xs:element name = “from” type = “xs:string”></xs:element>
    <xs:element name = “body” type = “xs:string”></xs:element>
    </xs:schema>

    I cannot load this document

    hello
    2002-05-06
    joe@softwareag.com
    michael
    bye bye


    This loads if I change the data type from xs:date
    to xs:string

    What am I doing wrong?

    Thanks,
    Jeff M.


    #Tamino
    #API-Management
    #webMethods


  • 2.  RE: using xs:date in Tamino schema

    Posted Tue May 07, 2002 12:05 PM

    Hi Jeff,

    I tried this with Tamino 3.1.1.4 and I can successfully define and store the XML document. I must admit I changed the sample document slightly just to include the xml prolog. Which patch level of Tamino do you use and what error do you get? Maybe installing the latest PL will solve this problem.

    Kind regards, Stuart


    #Tamino
    #API-Management
    #webMethods


  • 3.  RE: using xs:date in Tamino schema

    Posted Tue May 07, 2002 12:06 PM

    When using Tamino 3.1.1.4 (York) I did not have any problem to store the document using your schema (after adding the XML declaration to the XML instance).
    Which error message did you receive when attempting to store the document?


    #Tamino
    #API-Management
    #webMethods


  • 4.  RE: using xs:date in Tamino schema

    Posted Wed May 08, 2002 12:44 AM
    <?xml version="1.0" encoding="iso-8859-1" ?>
    -
    -
    document processing started

    -
    An invalid value has been found during validation.
    Line 4, Column 2: datatype validation for element "date" of type xs:decimal failed:


    #webMethods
    #API-Management
    #Tamino


  • 5.  RE: using xs:date in Tamino schema

    Posted Wed May 08, 2002 09:53 PM

    Hi Jeff
    thats indeed the message which I did observe when changing the (valid) date in your sample document. May be there was a bug with validation vs. xs:date in the Newcastle release!?
    Best regards
    Uli


    #Tamino
    #webMethods
    #API-Management


  • 6.  RE: using xs:date in Tamino schema

    Posted Fri May 10, 2002 08:11 PM

    Hi Everyone,

    I think that some lateral thought is required here: the error message mentions that the value is invalid for type “xs:decimal” - perhaps the type of “date” has been changed (for experimentation, perhaps) since the posted schema, and the type of date is in fact “xs:decimal” in Jeff’s Tamino.

    This would explain the problem, and is worth checking!

    Cheers,
    Trevor.


    #API-Management
    #Tamino
    #webMethods


  • 7.  RE: using xs:date in Tamino schema

    Posted Mon May 20, 2002 09:36 PM

    This is working great now. My issue is solved!


    #Tamino
    #API-Management
    #webMethods