CONFERENCE PAPER

Element Order Is Always Important in XML, Except When It Isn’t

When ordered elements can be moved then we have something that has some common ground with orderless. This paper establishes a continuum between ordered information and orderless information and proposes that these are not as far apart as they might at first appear.

Orderless doesn’t have to be so scary

“Which came first,” begins an old joke. But the more interesting question might be, “does it even matter?” There are many obvious and several not-so-obvious ways in which the order of items (be they XML elements or attributes, or JSON maps or arrays) can be understood to be significant or insignificant. These are not new questions and how they’re answered plays out across vocabulary design, schema design, and individual documents. They are important questions when it comes deciding if two documents are “the same” or “different” and to what extent.

This paper challenges the one-size-fits-all decree in XML that order needs to be preserved and reviews the implications of ‘order’.

Download this conference paper to:

  • Review best practices when handling order in XML.
  • Review how JSON handles order and how JSON object and arrays compare with XML elements and attributes.
  • Understand when changes in order within XML documents and data matter and when they don’t.
  • Review how changes to order affect schema languages.

Knowing whether or not order is important is essential to the process of determining whether or not two XML documents are the same or different.

Related Media

JSON is now a widely used format for data both in web applications and more generally. However, systems and APIs that exchange JSON haven’t been able to take advantage of tracking tools. Can this be helped by processing JSON as XML?

This paper describes how a divide-and-conquer approach might be used to handle the complex markup structure that results from recording multiple variants of an historical document in a single XML document.

Presented at Tekom 2020, Product Director Tristan Mitchell demonstrates how to create additional revenue around your document-based products by providing value-add to your customers.