Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Gyration

Pages: [1]
1
PSOUG / Re: Date
« on: November 26, 2009, 12:47:16 AM »
Here is my sample query: 
 
SELECT
TO_CHAR(c.END_DATE,'Month YYYY') years,
SUM (b.plan_total_lcl) plan_total,
SUM (b.actual_total_LCL) actual_total


FROM KCST_BUDGET_PERIOD_SUM a,

KCST_CURRENCY_LINES b,

KNTA_PERIODS c

WHERE a.BUDGET_ID = (SELECT z.PRJ_BUDGET_ID FROM KCRT_FG_PFM_PROJECT z WHERE z.REQUEST_ID = 43985)

AND a.currency_line_id = b.currency_line_id
AND c.period_id = a.period_id

GROUP BY TO_CHAR(c.END_DATE,'Month YYYY')

ORDER BY 1


Results:

YEARSPLAN_TOTALACTUAL_TOTAL
October   2009160,562.00181,860.00
August    2009160,562.00222,495.00
November  2009160,562.00150,990.00
July    2009160,562.00129,990.00
December  2009160,562.000.00
September 2009160,562.00198,870.00
June    2009963,374.00952,539.00


I need the SUM of PLAN_TOTAL form June 2009 to Septermber 2009
 
D

2
PSOUG / Date
« on: November 25, 2009, 06:02:21 AM »
Hi guys, I'm new in this forum. I need help.

I want the sum of, lets say electricity bill for a specific person according to a period of time.

say the sum of a person's electricity bill from March 2009 to July 2009.

Anyone for assistance?


Pages: [1]