need sum of a column based upon another column's grouping [message #655594] |
Mon, 05 September 2016 05:44 |
m_shehpar
Messages: 73 Registered: October 2010 Location: Pakistan
|
Member |
|
|
Hi all,
I have a scenario in a matrix report, the report is all ready by its row-wise and column wise data representation. Now i have another column (CS_DEPR) which exists in the same group but I want to show it one time and take its sum at the end of the report. But the problem is, it has data for each line of the matrix column (which due to matrix has been shown row wise). But i have to show this column only one time and take sum of it in the end.
I have attached the snapshot of my .RDF report. My template file (please save as .rtf before using it) and the xml datafile.
The .rtf file is the template of a matrix report, which runs all very fine. I need another column "Depreciation" which is shown only once (which is fine also) but the sum (sub total) gets erroneous, since Depreciation column has a value (same for each matrix column) and it sums up for each column
The xml file which i have attached, only group G_VTI is used in the .rtf file. A snapshot of .RDF has also been attached.
Thanking in anticipation.
Regards
Shabbir
|
|
|
Re: need sum of a column based upon another column's grouping [message #655595 is a reply to message #655594] |
Mon, 05 September 2016 05:49 |
m_shehpar
Messages: 73 Registered: October 2010 Location: Pakistan
|
Member |
|
|
xml data file data is below while report RDF snapshot has also been attached:
<?xml version="1.0" encoding="WINDOWS-1252"?>
<!-- Generated by Oracle Reports version 10.1.2.0.2 -->
<PVTCRHRB>
<LIST_G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Depreciation - Office Equipments</NAT>
<BALANCE>10000.0000000000000000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Depreciation - Building on Freehold Land</NAT>
<BALANCE>50000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Miscellaneous Expenses</NAT>
<BALANCE>1690000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2102</VTI_CODE>
<VTI>VTI Governer House</VTI>
<NAT>Miscellaneous Expenses</NAT>
<BALANCE>300000</BALANCE>
<LIST_G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR></CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Security Expenses</NAT>
<BALANCE>140000.000000000000000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2102</VTI_CODE>
<VTI>VTI Governer House</VTI>
<NAT>Office Supplies</NAT>
<BALANCE>13560</BALANCE>
<LIST_G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR></CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2201</VTI_CODE>
<VTI>VTI Gujranwala</VTI>
<NAT>Salaries & Wages</NAT>
<BALANCE>195000</BALANCE>
<LIST_G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR></CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2204</VTI_CODE>
<VTI>VTI Sheikhupura</VTI>
<NAT>Office Supplies</NAT>
<BALANCE>205000.000000000000000</BALANCE>
<LIST_G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR></CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Depreciation - Lab Equipments</NAT>
<BALANCE>60000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Depreciation - Electronic / IT / Communication Equipments</NAT>
<BALANCE>40000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Leave Fare Assistance</NAT>
<BALANCE>100000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Misc. Project Expense</NAT>
<BALANCE>270000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2102</VTI_CODE>
<VTI>VTI Governer House</VTI>
<NAT>Salaries & Wages</NAT>
<BALANCE>200000.000000000000000</BALANCE>
<LIST_G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR></CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Office Supplies</NAT>
<BALANCE>75000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Depreciation - Vehicle</NAT>
<BALANCE>95000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Depreciation - Furniture & Fixture</NAT>
<BALANCE>55000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
<G_VTI>
<VTI_CODE>2113</VTI_CODE>
<VTI>VTI Green Town</VTI>
<NAT>Salaries & Wages</NAT>
<BALANCE>100000</BALANCE>
<LIST_G_SEGMENT2>
<G_SEGMENT2>
<DEPR>352000.000000000000000</DEPR>
<SEGMENT2>2113</SEGMENT2>
</G_SEGMENT2>
</LIST_G_SEGMENT2>
<CS_DEPR>352000.000000000000000000000000000000000</CS_DEPR>
</G_VTI>
</LIST_G_VTI>
<CF_BUD_PERIOD>'JUN-16</CF_BUD_PERIOD>
<CF_DUR_MON>12</CF_DUR_MON>
<CF_BUDGET>BUDGET_2015-16</CF_BUDGET>
<CF_REGION>Center Region</CF_REGION>
</PVTCRHRB>
[mod-edit: image inserted into message body by bb]
[Updated on: Mon, 05 September 2016 17:05] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|