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.  Attributes for the root element

    Posted Thu October 24, 2002 04:39 AM

    Hello,

    I’m new to QuiP and I can’t really figure out why my queries work when I have no attributes for the root element and don’t work when I do have some attributes.

    For instance, a query on













    works just fine, while a query on













    does not generate any results.

    Is it an unlisted limitation of the program?

    Thanks,
    Sorin.


    #API-Management
    #webMethods
    #Tamino


  • 2.  RE: Attributes for the root element

    Posted Fri October 25, 2002 02:11 PM

    Specifying xmlns=“some.uri” on the outermost element of your XML document changes the names of all the elements in the document. The name of an element has two parts, the namespace URI and the local name. By adding a default namespace declaration, you have changed the name of the element (for example) from (namespace=null, localname=“Director”) to (namespace=“some.uri”, localname=“Director”).

    In XQuery or XPath, if you want to match on a name in a non-null namespace, you must include a namespace prefix. You need to write the name as dd:Director and to include a namespace declaration that associates the prefix “dd” with the URI “some.uri”.

    XQuery does have a way of declaring the default namespace for unprefixed element names appearing in path expressions, but as far as I know it’s not implemented in QuiP at this stage.

    Michael Kay


    #webMethods
    #Tamino
    #API-Management


  • 3.  RE: Attributes for the root element

    Posted Fri October 25, 2002 07:27 PM

    Thank you for the reply. It does make a great deal of sense. Thanks.

    Sorin.


    #webMethods
    #API-Management
    #Tamino