[Bug 4443] Unspecified how unprefixed attributes with namespace URIs are to be treated

http://www.w3.org/Bugs/Public/show_bug.cgi?id=4443

           Summary: Unspecified how unprefixed attributes with namespace
                    URIs are to be treated
           Product: XPath / XQuery / XSLT
           Version: Recommendation
          Platform: Other
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: XQuery
        AssignedTo: chamberl@almaden.ibm.com
        ReportedBy: frans.englich@telia.com
         QAContact: public-qt-comments@w3.org


The following query:

<e>
        {
                attribute {QName("http://example.com/", "attr")} {()}
        }
</e>

produce an attribute whose name doesn't have a prefix but does have a non-empty 
namespace URI, and is added to an element. This cannot be serialized without a
prefix for the attribute, which above is absent. Apparently this is not
discussed in the specifications.

It might be useful to see XSL-T's take on this. Sections 5.7.3 Namespace Fixup
and 11.3 Creating Attribute Nodes Using xsl:attribute may be of particular
importance.

(XSL-T 5.7.3 says "Namespace fixup may, if necessary to resolve conflicts,
change the namespace prefix contained in the QName value that holds the name of
an element or attribute node," but I don't see how such conflicts can occur in
XQuery due to XQDY0025. But maybe there's some other additional namespace case
that XQuery doesn't cover.)

First raised on w3c-xml-query-wg@w3.org(member-only link):
http://lists.w3.org/Archives/Member/w3c-xml-query-wg/2007Apr/0000.html

Received on Monday, 2 April 2007 08:11:21 UTC