[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: ANN: a portable data component -- length

  • From: Kurt Cagle <kurt.cagle@gmail.com>
  • To: John Cowan <cowan@mercury.ccil.org>
  • Date: Sat, 9 Apr 2011 16:39:58 -0400

Re:  ANN: a portable data component -- length
Distances are obviously simple scalar conversions and are fixed, but consider the issue of prices and currency conversion:

<price currency="USD">34.52</price>

In this case, if I wanted to convert the same price into pounds sterling, it's not in fact a straightforward fixed conversion rate, but will depend upon multiple factors - the date that the transaction took place, any conversion charges that may apply and so forth.

<price currency="USD">34.52</price>
<price currency="UKP">18.32</price>

If this is in fact recording a transaction, and the conversion rate is not in fact discoverable (and that's perhaps the biggest issue here) the idea of incorporating the units into the instance makes sense - the transaction costs involved in discovering the equivalences are higher than the cost of carrying the data in the first place. To me that should be the bigger decision determinant when talking about replication of information - is the cost of replication less than the cost of computation when the data is re-referenced.

I've seen that recently on specific MarkLogic projects. Certain information was in fact derivable from other information, but the derivation costs were pretty dramatic and couldn't be indexable. In that particular case, it made more sense to derive the relevant values and store them with the calling data as a key, even though such a field meant that the dataset was not formally normalized.

Of course, what this means in practice is that there really is no best practice with regards to units and conversions; it depends upon your requirements as to whether you derive or replicate.

Kurt Cagle
Invited Expert, XForms Working Group, W3C
Managing Editor, XMLToday.org




On Sat, Apr 9, 2011 at 3:57 PM, John Cowan <cowan@mercury.ccil.org> wrote:
Amelia A Lewis scripsit:

> Or, to quote the storied wisdom of the ancients: a man with one clock
> always knows what time it is. A man with two is never sure.

There's an opposite point of view, though:  "Sure, what would we be wanting
with two clocks if they both told the same time?"

--
Kill Gorgun!  Kill orc-folk!            John Cowan
No other words please Wild Men.         cowan@ccil.org
Drive away bad air and darkness         http://www.ccil.org/~cowan
with bright iron!   --Ghan-buri-Ghan    http://www.ccil.org/~cowan

_______________________________________________________________________

XML-DEV is a publicly archived, unmoderated list hosted by OASIS
to support XML implementation and development. To minimize
spam in the archives, you must subscribe before posting.

[Un]Subscribe/change address: http://www.oasis-open.org/mlmanage/
Or unsubscribe: xml-dev-unsubscribe@lists.xml.org
subscribe: xml-dev-subscribe@lists.xml.org
List archive: http://lists.xml.org/archives/xml-dev/
List Guidelines: http://www.oasis-open.org/maillists/guidelines.php




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


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.