XML.orgXML.org
FOCUS AREAS |XML-DEV |XML.org DAILY NEWSLINK |REGISTRY |RESOURCES |ABOUT
OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]
Namespaces enable recognition of the type of document, but whatabout recognition of the instance?


Hi Folks,

Consider a task that receives various types of documents. The task needs to "recognize" the type of each document to enable subsequent processing.

The type of an XML document can be recognized by its namespace. Thus, a task at a health-care insurance company can recognize the following XML document is an insurance claim by examining its namespace:

    <Claim xmlns="http://www.health-care.org/insurance/claim/";>
      <patient>John Smith</patient>
      <doctor>Dr. Sara Johnson</doctor>
      <procedure>Yearly physical</procedure>
      <charges>$69.00</charges>
    </Claim>

Suppose a doctor and a patient mistakenly file the same claim. The two documents contain the same information. As we've seen, namespaces enable the task at the insurance company to recognize that the two documents are both claims, but it does not enable the task to distinguish between the claim filed by the doctor and the claim filed by the patient. The task is confused when it processes the second claim:

     Is this the same claim that I processed
     earlier (i.e. a system error), or is it  
     a different claim for the same procedure
     (user error)?"

Thus, namespaces enable recognition of the type of document, but not the instance. Recognition of both are important.

One solution is to include an enterprise-wide identifier in each claim. Here is the claim the doctor files:

    <Claim xmlns="http://www.health-care.org/insurance/claim/";>
      <id>A309PX</id>
      <patient>John Smith</patient>
      <doctor>Dr. Sara Johnson</doctor>
      <procedure>Yearly physical</procedure>
      <charges>$69.00</charges>
    </Claim>

And here is the claim the patient files:

    <Claim xmlns="http://www.health-care.org/insurance/claim/";>
      <id>ZZ34RJ</id>
      <patient>John Smith</patient>
      <doctor>Dr. Sara Johnson</doctor>
      <procedure>Yearly physical</procedure>
      <charges>$69.00</charges>
    </Claim>

Now the task at the insurance company can recognize that: 

- both documents are claims, and 
- two separate claims have been submitted for the same procedure (i.e. user error).


QUESTIONS

1. Is it best practice to include an enterprise-wide identifier in each business document?

2. Is it best practice to use namespaces to identify the type of an XML document, and an enterprise-wide identifier to identify the instance?

3. Is there a standard for creating enterprise-wide identifiers?

4. Is there a standard way of expressing enterprise-wide identifiers in an XML document?

   - above I used a very simple <id>...</id> element

5. Is the requirement for an enterprise-wide identifier something that you would put in a business requirement's document, or is it something that a system implementer adds on his own initiative? 


/Roger


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index]


News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 1993-2007 XML.org. This site is hosted by OASIS