Thursday, September 29, 2011

Rounded Values of Essence Aliased Facts Now Checked

I have just checked in code that will be released with the next CTP of Gepsio. The code validates the rounded values (that is, fact values with any applicable rounding and truncation applied) of essence aliased facts and throws an exception if those values do not match.

For example, consider the following XBRL document:

<xbrl xmlns="" xmlns:link="" xmlns:xlink="" xmlns:example="" xmlns:iso4217="" xmlns:xsi="" xsi:schemaLocation=" EssenceAlias.xsd">
<link:schemaRef xlink:href="EssenceAlias.xsd" xlink:type="simple"/>
<unit id="u1">
<context id="c1">
<identifier scheme="">example</identifier>
<example:CurrentDeferredIncomeTaxExpense contextRef="c1" unitRef="u1" precision="4">100.0</example:CurrentDeferredIncomeTaxExpense>
<example:ForeignDomesticIncomeTaxExpense contextRef="c1" unitRef="u1" precision="3">100</example:ForeignDomesticIncomeTaxExpense>
<example:TaxExpense contextRef="c1" unitRef="u1" precision="3">200</example:TaxExpense>

Now suppose that the CurrentDeferredIncomeTaxExpense and TaxExpense facts are paired in an essence alias relationship, as shown in the following linkbase document:

<?xml version="1.0" encoding="UTF-8"?>
<linkbase xmlns="" xmlns:xbrll="" xmlns:xlink="" xmlns:xsi="" xsi:schemaLocation=" ../lib/xbrl-linkbase-2003-12-31.xsd">
<definitionLink xlink:type="extended" xlink:role="">
<loc xlink:type="locator" xlink:href="EssenceAlias.xsd#TaxExpense" xlink:label="labelTaxExpense" xlink:title="TaxExpense"/>
<loc xlink:type="locator" xlink:href="EssenceAlias.xsd#ForeignDomesticIncomeTaxExpense" xlink:label="labelForeignDomesticIncomeTaxExpense" xlink:title="ForeignDomesticIncomeTaxExpense"/>
<loc xlink:type="locator" xlink:href="EssenceAlias.xsd#CurrentDeferredIncomeTaxExpense" xlink:label="labelCurrentDeferredIncomeTaxExpense" xlink:title="CurrentDeferredIncomeTaxExpense"/>
<definitionArc xlink:type="arc" xlink:arcrole="" xlink:from="labelTaxExpense" xlink:to="labelCurrentDeferredIncomeTaxExpense" priority="0"/>
<definitionArc xlink:type="arc" xlink:arcrole="" xlink:from="labelTaxExpense" xlink:to="labelForeignDomesticIncomeTaxExpense" priority="0"/>

The XBRL document is invalid, because the two facts are in an invalid essence alias relationship. The relationship is invalid because the rounded values of the facts differ. In the current CTP, this issue is not reported by Gepsio. Starting with the next CTP, this issue will be reported during validation through an XbrlException thrown back to the caller. The exception will contain a message describing the mismatched values. For the document above, Gepsio will provide a message that reads as follows:

Facts named TaxExpense are defined as being in an essence alias relationship with facts named CurrentDeferredIncomeTaxExpense. However, the fact with ID  has a rounded value of 200, which differs from the fact with ID , which has a rounded value of 100. These two facts are therefore not in a valid essence alias relationship.

(Gepsio will include the fact IDs in the message. The document shown above has no IDs for the facts, so that part of the message is empty.)

No comments:

Post a Comment