src-db/database/sourcedata/AD_TABLE.xml
changeset 24880 0f496c17e6b7
parent 24865 ae70656351d2
child 24935 6db920aa9c1e
--- a/src-db/database/sourcedata/AD_TABLE.xml	Wed Sep 10 23:58:35 2014 +0200
+++ b/src-db/database/sourcedata/AD_TABLE.xml	Thu Sep 11 16:31:31 2014 +0200
@@ -11378,7 +11378,7 @@
       join lcra.goodsShipmentLine as iol
       where lcra.landedCostCost = lcc)
   ) as products,
-  lcm.amount as amttomatch,
+  lcm.amountInInvoiceCurrency as amttomatch,
   (select sum(otherlcm.amount)
    from LandedCostMatched as otherlcm
    where otherlcm.landedCostCost = lcc
@@ -11398,7 +11398,8 @@
   lcc.id as m_lc_cost_id,
   lc.documentNo as documentNo,
   lcc.lineNo as line,
-  case when 1=1 then false else true end as processMatching
+  case when 1=1 then false else true end as processMatching, 
+  lcc.currency.iSOCode as currency
 from LandedCostCost as lcc
   join lcc.landedCost as lc
   join lcc.landedCostType as lct
@@ -11407,7 +11408,7 @@
 where (lcc.isMatchingAdjusted = false or lcm is not null)
   and @additional_filters@
   and @insertion_point_0@
-group by  coalesce(lcm.id, lcc.id), lcc, lct.name, lcc.amount, lcm.amount, case when lcm is not null then true else false end, lc.referenceDate, lcc.matched, lcc.isMatchingAdjusted, lcm.id, lcc.id, il, lc.documentNo, lcc.lineNo]]></HQLQUERY>
+group by  coalesce(lcm.id, lcc.id), lcc, lct.name, lcc.amount, lcc.currency.iSOCode, lcm.amount, case when lcm is not null then true else false end, lc.referenceDate, lcc.matched, lcc.isMatchingAdjusted, lcm.id, lcc.id, il, lc.documentNo, lcc.lineNo, lcm.amountInInvoiceCurrency]]></HQLQUERY>
 <!--B2960E2BDCCD4F7599A2433F2681847F-->  <ENTITY_ALIAS><![CDATA[lcc]]></ENTITY_ALIAS>
 <!--B2960E2BDCCD4F7599A2433F2681847F--></AD_TABLE>