Hourly Running Total

Hi experts,
Need your expert helping hand for one of the reports I am currently working on.
This report runs every hour 12:00, 13:00 ... so on and the requirement is to produce Running Total of Stock_Shortages every hour.
As of now I had the requirement to produce just the hourly figures for which I used the following query
SELECT
to_char(SALES_ORDER_HEADER.SOH_DATE_RELEASED,'dd/mm/yyyy') as RELEASED_DATE,
substr(to_char(SALES_ORDER_HEADER.SOH_TIME_RELEASED,'HH24:MI:SS'),1,2) as RELEASED_TIME,
SOH_CLASS as CLASS,
count(SALES_ORDER_HEADER.SOH_ORDER_NO) as Stock_Shortage
FROM
COM.SALES_ORDER_HEADER SALES_ORDER_HEADER
WHERE
SOH_STATUS ='05'
AND SOH_DATE_RELEASED = TRUNC(SYSDATE)
AND substr(to_char(SALES_ORDER_HEADER.SOH_TIME_RELEASED,'HH24:MI:SS'),1,2) < substr(to_char(sysdate,'HH24:MI:SS'),1,2)
GROUP BY
to_char(SALES_ORDER_HEADER.SOH_DATE_RELEASED,'dd/mm/yyyy'),
substr(to_char(SALES_ORDER_HEADER.SOH_TIME_RELEASED,'HH24:MI:SS'),1,2)
How can I amend this query to show the cumulative total of Stock_Shortage at the end of each hour ?
Plssss help....

Something like this, perhaps?
with my_table as (select 1 id, to_date('30/09/2009 12:15:43', 'dd/mm/yyyy hh24:mi:ss') dt, 10 amt from dual union all
                  select 1 id, to_date('30/09/2009 14:26:42', 'dd/mm/yyyy hh24:mi:ss') dt, 20 amt from dual union all
                  select 1 id, to_date('30/09/2009 14:35:36', 'dd/mm/yyyy hh24:mi:ss') dt, 30 amt from dual union all
                  select 1 id, to_date('30/09/2009 15:06:32', 'dd/mm/yyyy hh24:mi:ss') dt, 40 amt from dual union all
                  select 1 id, to_date('30/09/2009 15:59:43', 'dd/mm/yyyy hh24:mi:ss') dt, 50 amt from dual union all
                  select 2 id, to_date('30/09/2009 12:23:31', 'dd/mm/yyyy hh24:mi:ss') dt, 60 amt from dual union all
                  select 2 id, to_date('30/09/2009 12:49:19', 'dd/mm/yyyy hh24:mi:ss') dt, 70 amt from dual union all
                  select 2 id, to_date('30/09/2009 16:42:06', 'dd/mm/yyyy hh24:mi:ss') dt, 80 amt from dual union all
                  select 3 id, to_date('30/09/2009 14:35:21', 'dd/mm/yyyy hh24:mi:ss') dt, 90 amt from dual union all
                  select 3 id, to_date('30/09/2009 14:58:20', 'dd/mm/yyyy hh24:mi:ss') dt, 100 amt from dual union all
                  select 4 id, to_date('30/09/2009 17:05:49', 'dd/mm/yyyy hh24:mi:ss') dt, 110 amt from dual),
      results as (select id,
                         trunc(dt, 'hh24') by_hour,
                         sum(amt) over (partition by id order by trunc(dt, 'hh24')) running_total
                  from   my_table)
select id,
       to_char(by_hour, 'dd/mm/yyyy hh24:mi:ss') by_hour,
       running_total,
       count(id) total_amt
from   results
group by id,
         by_hour,
         running_total
order by id,
         by_hour;
        ID BY_HOUR             RUNNING_TOTAL  TOTAL_AMT
         1 30/09/2009 12:00:00            10          1
         1 30/09/2009 14:00:00            60          2
         1 30/09/2009 15:00:00           150          2
         2 30/09/2009 12:00:00           130          2
         2 30/09/2009 16:00:00           210          1
         3 30/09/2009 14:00:00           190          2
         4 30/09/2009 17:00:00           110          1

Similar Messages

  • Graphing a RUNNING TOTAL on a line graph

    So I'm having a lot of trouble putting my data on a chart. I have it all laid out here: files.me.com/redsteven1/glwk4v.numbers.zip
    Whenever I try to graph it though I run into a whole host of problems. Namely, that I can't get the values to plot on the chart at all.
    Not sure what the problem is... I select A2:G103... and I see the different series (for each Activity) show up in the legend, but nothing is plotted on the chart.
    I know that much of the table is blank... that's because I'll be adding to it every day.
    Ideally, the X-axis should be time/date.... May, June, July, and August can be the major tick marks. And the Y-axis would be number of hours spent on each activity.
    To further complicate things, the chart should really be a running total of time spent on each activity... so if I spend an hour on Activity 1 each day for 3 days... then on the third day I should have a plot of 3 hours... not 1.
    I know I didn't work things super well here... hopefully you can figure out what I mean by looking at the linked file : \
    Thanks in advance.

    I guess that line graph isn't the best one, I would use the Scatter one.
    You can't chart your datas as they are at this time.
    Every datas are date_time or duration values which can't be charted as is.
    Here, I converted the dates from column A into strings
    Then I added 6 columns in which I converted the durations into decimal hours.
    The original columns are hidden.
    The formula used to convert is a simple one.
    In H2, I inserted :     
    =STRIPDURATION(B)*24
    Fill to the right
    Fill Down
    to fill the other cells.
    Yvan KOENIG (VALLAURIS, France) dimanche 22 mai 2011 21:26:18
    Please :
    Search for questions similar to your own before submitting them to the community
    To be the AW6 successor, iWork MUST integrate a TRUE DB, not a list organizer !

  • Running Total Variation Query Time Optimization

    Hi all, 
    I've been struggling with this query for a while. I need to set a customer specific running total for 10 million rows (reset for every customer). But every time the number goes negative, I need to set it as zero.
    For example,
    member no              amount            wallet
    member1                 400                      400
    member1                 -500                     0
    member1                  200                    200
    member2                  700                    700
    member2                 -200                    500
    Query:
    DECLARE @member float
    DECLARE @prev_member float
    DECLARE @amount float
    DECLARE @wallet float
    DECLARE db_cursor CURSOR FOR  
    SELECT [Member no], [Transaction Amount] 
    FROM [wallet_master_3]
    ORDER BY [Member No], [rownum]
    FOR UPDATE
    OPEN db_cursor
    FETCH NEXT FROM db_cursor INTO @member, @amount
    SET @prev_member = @member
    set @wallet=0
    WHILE @@FETCH_STATUS = 0
    BEGIN   
           IF @prev_member <> @member set @wallet=0
           SET @wallet = @wallet + @amount
           IF @wallet < 0 SET @wallet = 0
           UPDATE [wallet_master_3] SET walletsize = @wallet
           WHERE CURRENT OF db_cursor
           set @prev_member=@member
           FETCH NEXT FROM db_cursor INTO @member, @amount
    END   
    CLOSE db_cursor   
    DEALLOCATE db_cursor
    I've tried using a cursor. In five minutes, it ran 17,000 rows but after running it for 15 hours, the code only manages to set the running total for 175,000 rows. I'm not exactly sure why. Is there a faster approach I can use? 
    Thanks!

    As an exercise a 'Quirky Update' may help you in this scenario. Try the below trick!
    DECLARE @Wallet AS TABLE
    MemberNo VARCHAR(10),
    RowNum INT,
    Amount INT,
    Wallet INT
    INSERT INTO @Wallet (MemberNo, RowNum, Amount) VALUES
    ('member1',1, 400),
    ('member1',2, -500),
    ('member1',3, 200),
    ('member2',1, 700),
    ('member2',2, -200)
    DECLARE @RunTotal AS INT
    UPDATE W1
    SET
    @RunTotal = W1.Wallet =
    CASE
    WHEN W1.RowNum = 1 THEN W1.Amount
    WHEN @RunTotal + COALESCE(W1.Amount, W2.Amount) < 0 THEN 0
    ELSE @RunTotal + COALESCE(W1.Amount, W2.Amount)
    END
    FROM @Wallet W1
    LEFT OUTER JOIN @Wallet W2
    ON W1.MemberNo = W2.MemberNo AND W2.RowNum = W1.RowNum - 1;
    SELECT * FROM @Wallet;
    RESULT
    MemberNo RowNum Amount Wallet
    member1 1 400 400
    member1 2 -500 0
    member1 3 200 200
    member2 1 700 700
    member2 2 -200 500
    You can read more on 'Quirky Update' in below articles
    Solving the Running Total and Ordinal Rank Problems - Jeff Moden
    Robyn Page's SQL Server Cursor Workbench
    NOTE: Please test it thoroughly before using in a production environment!
    Krishnakumar S

  • Require a formula to calc the diff between 2 running total fields in a crosstab

    Post Author: PJM
    CA Forum: General
    Hi,
    I have built a crosstab in Crystal XI with the following columns:
    PROFILED BUDGET (a)                            EXPENDITURE TO DATE (b)                        VARIANCE (a-b)
    The profiled budget and expenditure to date columns are both running total fields.  I want the variance column to show the difference between the budget and expenditure. 
    To set the variance field up as a running total, I assume that I would have to specify that I want this formula evaluated after the budget and expenditure fields , however, I can't work out how to do this on a crosstab. 
    Moving the crosstab to the report footer has had no impact.
    If I try to create a basic formula using the running totals, I get the error message "A summary has been specified on a  non-recurring field" - I can't find an explanation of this error message on the help menu.
    Can anyone help with this please?

    overtime hours are calculated after 40. If I work 12 on monday, thats 12 regulars hours. not sure about others states laws but here in wisconsin we consider overtime after 40 only, not after 8 daily. at least thats how my company calculates overtime. lets say I work 10 hours a day, monday thru thursday, thats 40 hours regular time. anything after that is overtime. our weekly work schedule starts on sunday and ends on saturday. so on my bi-weekly time log, if i work 10 hrs a day monday thru thursday, i want 10hrs each day in regular hours cell, then when i work friday and or saturday, i want those hours in overtime hours. the main problem im having is: if i reach 40 hours in the middle of a day, i want the regular of that day to end and the overtime to pick up on the same day.
    here is a basic example of how i want regular and overtime to look. of course the values will be duration not just numbers. hope this helps explain what i need a bit better.

  • Running Total Issue or Possibly Formula Issue in Crystal Reports 9

    Post Author: Jeffs23
    CA Forum: Formula
    My issue involves two formula's - @TotalTime and @Converted Time and a Running Total (RTotal0).
    @TotalTime{Data.ApptTime}/60@Converted Timenumbervar x := {#RTotal0};totext(truncate(x),0,"")" Hrs "totext(remainder(x,truncate(x))*60,0,"") + " Mins"Running Total (RTotal0)
    Field to Summarize - @TotalTime
    Type of Summary - sum
    Under Evaluate Section:
    "Use a Formula":
    onfirstrecord or
    {Data.ResourceStart} <> previous({Data.ResourceStart}) or
    {Data.Resource} <> previous({Data.Resource})
    ) and
    minimum({Data.ApptKind},{Data.ResourceStart}) = 1 AND
    maximum({Data.Column},{Data.ResourceStart}) >= '1'
    Reset on change of field {Data.Resource}
    A little background:My report deals with a Doctors schedule. In the doctors schedule, a appointment is booked and is by default placed into Column 1. It always defaults to Column 1. If the provider elects to double book their time and schedule another patient at the exact same time, the second appointment hits column 2. It expands in essence. It is possible to have up to 4 appointments in one time slot. This is why we wait forever at the Doctors office - appointments get overbooked because patients cancel or no show frequently and the provider would rather have the patients wait then risk no appointment at all. My Client wants the "TOTAL TIME" a provider was "scheduled" to see patients, not the time they actually saw the patients. So if the Provider was scheduled to see patients from 8 am to noon and had patients doublebooked for every time slot, I only want to report the overall time he saw patients regardless of the doublebooking, triplebooking or quadruplebooking. So the total time for my example should be 4 hours not 8 hours. The good news is this is painfully close to being correct! What is currently happening, is if the schedule contains more than 1 facility the time calculates wrong.  I think my issue may be in the running Total but not 100% sure. I need it to calculate time on each facility - {Data.Facility}.

    Post Author: Jeffs23
    CA Forum: Formula
    I had some minor issues with my formulas and Running Total so I modified them alittle:
    @TotalTime
    If {Data.ApptTime} = 0 then    0else    {Data.ApptTime}
    @Converted Time
    If {#RTotal0} = 0 then    "--"else    ToText(Truncate({#RTotal0}/60),0,"") + " Hour(s), " + ToText(Remainder({#RTotal0},60),0,"") + " Min(s)"
    My running total stayed the same.......
    Field to Summarize - @TotalTime Type of Summary - sum Under Evaluate Section: "Use a Formula":(onfirstrecord or{Data.ResourceStart} <> previous({Data.ResourceStart}) or{Data.Resource} <> previous({Data.Resource}) ) andminimum({Data.ApptKind},{Data.ResourceStart}) = 1 AND maximum({Data.Column},{Data.ResourceStart}) >= '1' Reset on change of field {Data.Resource}
    Some fake sample data:
    Resource = Francis, William MD
    Facility 1: River Oaks Main Clinic
    Facility 2: Western Medical Hospital
    Date of Service = 10/25/2007
    From 7:15 am to 11:45 am, Patients were treated at Facility 1: River Oaks Main Clinic *** (total time = 4 hours 30 min)
    From 12:15 pm to 1:00 pm, Patients were treated at Facility 2: Western Medical Hospital *** (total time = 45 min)
    From 1:00 pm to 3:15 pm, Patients were treated at Facility 1: River Oaks Main Clinic *** (total time = 2 Hours 15 min)
    The report should tell me Total time at River Oaks Main Clinic = 6 Hours 45 min and 45 min for Western Medical Hospital. What it currently is doing, is reporting the 6 Hours 45 min on the River Oaks Main Clinic and 7 Hours 30 min on the Western Medical Hospital. The time for this facility should be 45 minutes, yet its taking the full provider time and throwing it into this second facility. I am assuming its because the Running total tells it "Reset on change of field {Data.Resource}". Somehow, I need it to evaluate on both the Resource and the Facility. Any suggestions?

  • Running total and Next function in Crosstab

    <strong><font size="3"><font face="Times New Roman">Clarifications on getting Next Running sum and count on a Crosstab</font></font></strong><font face="Times New Roman" size="3"> </font> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Here is the example, which I am working on:</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Highlights of the Report:</font></p><p style="margin: 0in 0in 0pt 0.5in; text-indent: -0.25in; tab-stops: list .5in" class="MsoNormal"><font face="Times New Roman"><span><font size="3">-</font><span style="font: 7pt &#39;Times New Roman&#39;">         </span></span><font size="3">Report is grouped on {Scenario Name}</font></font></p><p style="margin: 0in 0in 0pt 0.5in; text-indent: -0.25in; tab-stops: list .5in" class="MsoNormal"><font face="Times New Roman"><span><font size="3">-</font><span style="font: 7pt &#39;Times New Roman&#39;">         </span></span><font size="3">Left side dates on any of the tables is {Version Date}</font></font></p><p style="margin: 0in 0in 0pt 0.5in; text-indent: -0.25in; tab-stops: list .5in" class="MsoNormal"><font face="Times New Roman"><span><font size="3">-</font><span style="font: 7pt &#39;Times New Roman&#39;">         </span></span><font size="3">Dates on the top header on any of the tables is {Fsc Week End Dt}</font></font></p><p style="margin: 0in 0in 0pt 0.5in; text-indent: -0.25in; tab-stops: list .5in" class="MsoNormal"><font face="Times New Roman"><span><font size="3">-</font><span style="font: 7pt &#39;Times New Roman&#39;">         </span></span><font size="3">Other formulae used in this report are:</font></font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">1) = ({Query1.Demand Qty})/100000</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Numerical values displayed in the "Original values" table.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">2) =</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">if {Query1.Scenario Name} = &#39;DLYPRD:ASCP-PRD:PRD&#39; </font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">THEN mid ({Query1.Scenario Name},13,3)</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">ELSE mid ({Query1.Scenario Name},13,6)</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Second column with value PRD in any of the tables.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">3) {next qty} = if not onlastrecord then next({@ShortDemandQty}) else 0;</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">(used in the "next values vertically" table)</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">4) - running total to calculate horizontally</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Evaluate - For each record</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Reset - On change of field: {Version Date}</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">5) - running total to calculate vertically.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Evaluate - For each record</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Reset - On change of field: {Fsc Week End Dt}</font></p><font face="Times New Roman" size="3"> </font> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">In this report design, when I go and change the Sort order in the Record Sort Expert, some of the values go for a toss. I got two cases where the vertical values are correct in one case and horizontal values are correct in another case.</font></p><font face="Times New Roman" size="3"> </font><strong><font size="3"><font face="Times New Roman">First Case:</font></font></strong> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Cumulative vertical values are correct.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal">&#160;</p><font face="Times New Roman" size="3"> </font><strong><font size="3"><font face="Times New Roman">Second Case:</font></font></strong> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Cumulative horizontal values are correct.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal">&#160;</p><font face="Times New Roman" size="3"> </font><strong><span style="color: blue"><font size="3"><font face="Times New Roman">Is there any way to consistisize both the horizontal and vertical running totals. I even tried forcing the evaluate & reset like below and clearing the record sort order, but it did not work:</font></font></span></strong><strong><span style="color: blue"><font face="Times New Roman" size="3"> </font></span></strong> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">1) - running total to calculate horizontally</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Evaluate - On change of field: {Fsc Week End Dt}</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Reset - On change of field: {Version Date}</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">2) - running total to calculate vertically.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Evaluate - On change of field: {Version Date}</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">Reset - On change of field: {Fsc Week End Dt}</font></p><font face="Times New Roman" size="3"> </font><strong><span style="color: blue"><font size="3"><font face="Times New Roman">And one more observation on the running total, how it works in the crosstab is, the total runs likes a spiral rather than resetting at the column or row level. Is there any way to restrict this?</font></font></span></strong><font face="Times New Roman" size="3"> </font> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">3) {next qty} = if not onlastrecord then next({@ShortDemandQty}) else 0;</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">(used in the "next values vertically" table)</font></p><font face="Times New Roman" size="3"> </font> <p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">For example, onlastrecord does not seem to work on the "next values vertically" crosstab, rather brings the record from the next column.</font></p><p style="margin: 0in 0in 0pt" class="MsoNormal"><font face="Times New Roman" size="3">For 3/7/2007 - 01/APR/07, the value is 157.84 which is incorrect and should be 0.</font></p><strong><span style="color: blue"><font size="3"><font face="Times New Roman">I need to get a next on the running total. Next (fld) doesnot work for running totals. Please guide me, how to get the next values for the running total fields.</font></font></span></strong>

    Post Author: redtop6683
    CA Forum: Formula
    Whoops I guess I should have mentioned that I've already tried using Sum and Round(Running Total, 2) and haven't had any luck.
    I also should have mentioned that Groupings 1 and 2 are sums, and that Running Total is a running total that changes on every change of the grouping.  There are 4 groupings.
    Grouping 1 (Employee Name)
    Grouping 1.1 (Shift)
    Grouping 1.2.1 (Payroll Department Code)
    Grouping 1.2.1.1 (Description)
    Below these 4 groupings is where the running total is.  The issue is that in the footer of grouping 1 is a field that sums the elapsed hours for the particular employee by each payroll department code, these are then summed using the running total.  The issue is as stated in the earler post that I can round these individual sums on the groupings, but I get the number on my running total to round differently as you can see by the earlier post's example.
    Thanks for the help.
    ~Jason

  • Running Total Value or Zero

    Post Author: jligget
    CA Forum: Formula
    Good afternoon,
    I have a 2 running totals that sums either debits or credits. There may be cases where there are no credits so in place of the sum I need to place zero's.
    The running total has a formula in it of {@detail transaction code} in &#91;'22', '32'&#93; and if so it then sums the amount field. (22 or 32 desingate a credit - I have another running total for a debit)
    The problem is that if no credits exist nothing gets summed and I get spaces in my running total field. How can I make it so that it will display zeros instead?
    Thanks,
    Jeannette

    Post Author: Jeffs23
    CA Forum: Formula
    I had some minor issues with my formulas and Running Total so I modified them alittle:
    @TotalTime
    If {Data.ApptTime} = 0 then    0else    {Data.ApptTime}
    @Converted Time
    If {#RTotal0} = 0 then    "--"else    ToText(Truncate({#RTotal0}/60),0,"") + " Hour(s), " + ToText(Remainder({#RTotal0},60),0,"") + " Min(s)"
    My running total stayed the same.......
    Field to Summarize - @TotalTime Type of Summary - sum Under Evaluate Section: "Use a Formula":(onfirstrecord or{Data.ResourceStart} <> previous({Data.ResourceStart}) or{Data.Resource} <> previous({Data.Resource}) ) andminimum({Data.ApptKind},{Data.ResourceStart}) = 1 AND maximum({Data.Column},{Data.ResourceStart}) >= '1' Reset on change of field {Data.Resource}
    Some fake sample data:
    Resource = Francis, William MD
    Facility 1: River Oaks Main Clinic
    Facility 2: Western Medical Hospital
    Date of Service = 10/25/2007
    From 7:15 am to 11:45 am, Patients were treated at Facility 1: River Oaks Main Clinic *** (total time = 4 hours 30 min)
    From 12:15 pm to 1:00 pm, Patients were treated at Facility 2: Western Medical Hospital *** (total time = 45 min)
    From 1:00 pm to 3:15 pm, Patients were treated at Facility 1: River Oaks Main Clinic *** (total time = 2 Hours 15 min)
    The report should tell me Total time at River Oaks Main Clinic = 6 Hours 45 min and 45 min for Western Medical Hospital. What it currently is doing, is reporting the 6 Hours 45 min on the River Oaks Main Clinic and 7 Hours 30 min on the Western Medical Hospital. The time for this facility should be 45 minutes, yet its taking the full provider time and throwing it into this second facility. I am assuming its because the Running total tells it "Reset on change of field {Data.Resource}". Somehow, I need it to evaluate on both the Resource and the Facility. Any suggestions?

  • Sum values to display total (running total)

    I apologize for posting such a rudimentary question but I haven't been able to find an answer by searching the forum.
    Basically, I have several sensor inputs that are all factored into an equation that yeilds heat output (btu/hour). I need to take this value, which I have iterating once every second, and add it to itself every time it increments. In other words, say the first value is 10 (btus), the next second the value is 16, the code calculates and displays a value of 26 on the front panel and waits for the next second (or whatever iteration I choose) at which time it will add the new value to the running total.
    Thanks for your input
    Jake 
    Solved!
    Go to Solution.

    The Loopback function (<--) is basically a miniature shift register.
    /Y
    LabVIEW 8.2 - 2014
    "Only dead fish swim downstream" - "My life for Kudos!" - "Dumb people repeat old mistakes - smart ones create new ones."
    G# - Free award winning reference based OOP for LV

  • Running Total and In Current Year Columns Source

    Hi all,
    What is the source for Running Total and In Current Year Columns from Absence Detail Screen.
    From Which tables can I get the information on those columns.
    Thanks in Advance

    Hello,
    I am still struck with Running Total Column
    When i fetch running total using this query it works for some of the employees
    SELECT SUM(ABSENCE_hours) from PER_ABSENCE_ATTENDANCES where person_id = <your person id> and absence_attendance_type_id = <your absence type id>
    As there are three different cases here as Days,Hours and No Balance
    I am missing the logic again here when it comes for no balance and days
    Thanks

  • Running total required but with different timing

    Hi All:
    I am using Oracle9i Enterprise Edition Release 9.2.0.6.0
    I want to write a query to display the statistics report with running total.
    I have written following query that return last 60 minutes activities.
    SELECT se.tserv_id,
    sum(decode(eu.category,'I',1,0)) Imp,
    sum(decode(eu.category,'E',1,0)) Exp,
    count(*) Total
    FROM service_events se, equipment_uses eu
    WHERE se.performed BETWEEN trunc(sysdate-60/1440,'mi')
    AND trunc(sysdate,'mi')
    AND se.tserv_id IN ('EXM','GROUNDED')
    AND eu.gkey = se.equse_gkey
    AND eu.category IN ('I','E')
    GROUP BY se.tserv_id;
    now I want to write a query that shows me the result of above query and running total as well
    But the different between current activity and running total is as follows
    Current Activity = Last 60 minutes activity
    Running Total = Total activities from the 08:00 am till sysdate.
    for example if this query executed on 11:00 am then the current activity values must be from 10:00 am to 11:00 am and the running total values must be from 08:00 am to 11:00 am
    The reason for running total starts at 08:00 am is that the shift starts from 08:00 am to next day 07:59 am.
    Can I write one single query for this?
    Similarly running total values must be start from last day 08:00 am to current date and time when I executed this query from 00:00 to 08:00 (12 midnight to 8am)
    if difficult then plz let me know that how can I find that if the time is from 00 hrs to 08 hrs then start time must be the last date 08:00 am to the current date and time.
    Thanks
    Hassan

    Dear Frnak
    Thanks for your reply and help
    Its really did what I want
    I mean to say that the result format is correct but the value of Total_day column is not correct.
    Following is the sample data from 19-Jun-2008 08:00 AM to 20-JUN-2008 08:00 AM
    TSERV_ID  EQUSE_GKEY     PERFORMED
    ===============================================
    EXM       5188958     19-Jun-2008 8:00:32 AM
    EXM       5185586     19-Jun-2008 9:03:34 AM
    EXM       5181960     19-Jun-2008 9:03:35 AM
    EXM       5173333     19-Jun-2008 9:03:35 AM
    EXM       5188263     19-Jun-2008 9:08:49 AM
    GROUNDED  5174055     19-Jun-2008 9:10:29 AM
    GROUNDED  5152887     19-Jun-2008 9:10:29 AM
    GROUNDED  5187512     19-Jun-2008 9:10:29 AM
    GROUNDED  5196303     19-Jun-2008 9:27:41 AM
    EXM       5196370     19-Jun-2008 9:29:50 AM
    EXM       5172045     19-Jun-2008 10:01:23 AM
    GROUNDED  5196269     19-Jun-2008 11:11:29 AM
    GROUNDED  5200219     19-Jun-2008 11:24:39 AM
    GROUNDED  5185246     19-Jun-2008 12:06:30 PM
    GROUNDED  5190134     19-Jun-2008 12:09:27 PM
    GROUNDED  5190475     19-Jun-2008 12:09:27 PM
    GROUNDED  5156065     19-Jun-2008 12:26:49 PM
    GROUNDED  5132287     19-Jun-2008 1:56:44 PM
    EXM       5189203     19-Jun-2008 2:29:17 PM
    EXM       5180158     19-Jun-2008 3:27:03 PM
    EXM       5149310     19-Jun-2008 3:37:31 PM
    EXM       5196303     19-Jun-2008 3:42:48 PM
    EXM       5192768     19-Jun-2008 4:03:51 PM
    EXM       5174055     19-Jun-2008 4:14:23 PM
    EXM       5200231     19-Jun-2008 4:45:51 PM
    EXM       5157151     19-Jun-2008 4:51:06 PM
    EXM       5159930     19-Jun-2008 5:01:36 PM
    EXM       5185237     19-Jun-2008 5:01:37 PM
    EXM       5195434     19-Jun-2008 5:01:37 PM
    EXM       5152887     19-Jun-2008 5:06:49 PM
    EXM       5196269     19-Jun-2008 5:06:49 PM
    EXM       5187512     19-Jun-2008 5:17:26 PM
    EXM       5190134     19-Jun-2008 5:59:24 PM
    GROUNDED  5101919     19-Jun-2008 6:44:36 PM
    GROUNDED  5101918     19-Jun-2008 6:44:37 PM
    GROUNDED  5101913     19-Jun-2008 6:44:37 PM
    EXM       5185735     19-Jun-2008 6:46:38 PM
    GROUNDED  5195475     19-Jun-2008 6:47:11 PM
    GROUNDED  5195361     19-Jun-2008 6:47:12 PM
    EXM       5132608     19-Jun-2008 7:02:23 PM
    GROUNDED  5195334     19-Jun-2008 7:10:32 PM
    GROUNDED  5190558     19-Jun-2008 7:10:32 PM
    EXM       5183029     19-Jun-2008 7:33:53 PM
    EXM       5183480     19-Jun-2008 7:39:12 PM
    EXM       5189566     19-Jun-2008 8:00:11 PM
    EXM       5181825     19-Jun-2008 8:15:57 PM
    EXM       5183537     19-Jun-2008 8:15:57 PM
    EXM       5180210     19-Jun-2008 9:08:27 PM
    GROUNDED  5193136     19-Jun-2008 9:58:23 PM
    EXM       5171510     19-Jun-2008 10:21:59 PM
    EXM       5185615     19-Jun-2008 10:48:14 PM
    EXM       5184737     19-Jun-2008 10:53:29 PM
    EXM       5195475     19-Jun-2008 11:51:16 PM
    EXM       5195476     20-Jun-2008 12:01:46 AM
    EXM       5190558     20-Jun-2008 12:12:17 AM
    EXM       5196473     20-Jun-2008 12:54:19 AM
    EXM       5183204     20-Jun-2008 1:20:34 AM
    GROUNDED  5192844     20-Jun-2008 1:28:24 AM
    GROUNDED  5174238     20-Jun-2008 1:28:24 AM
    GROUNDED  5193127     20-Jun-2008 1:28:24 AM
    GROUNDED  5185794     20-Jun-2008 1:29:09 AM
    GROUNDED  5192895     20-Jun-2008 3:04:23 AM
    GROUNDED  5193039     20-Jun-2008 3:04:23 AM
    GROUNDED  5195447     20-Jun-2008 3:04:23 AM
    GROUNDED  5190228     20-Jun-2008 3:04:24 AM
    GROUNDED  5179370     20-Jun-2008 3:04:24 AM
    GROUNDED  5190289     20-Jun-2008 3:04:24 AM
    GROUNDED  5174065     20-Jun-2008 3:04:24 AM
    GROUNDED  5192862     20-Jun-2008 5:04:42 AM
    GROUNDED  5199903     20-Jun-2008 5:04:42 AM
    EXM       5178176     20-Jun-2008 6:30:29 AM
    EXM       5185161     20-Jun-2008 6:46:14 AM
    EXM       5180226     20-Jun-2008 6:46:14 AM
    GROUNDED  5202026     20-Jun-2008 7:03:14 AM
    EXM       5101912     20-Jun-2008 7:07:14 AM
    GROUNDED  5176763     20-Jun-2008 7:25:27 AM
    GROUNDED  5185494     20-Jun-2008 7:25:27 AM
    EXM       5185295     20-Jun-2008 7:38:46 AM
    EXM       5173837     20-Jun-2008 7:49:15 AM
    GKEY     CATEGORY
    =================
    5101912     I
    5101913     I
    5101918     I
    5101919     I
    5132287     I
    5132608     I
    5149310     I
    5152887     I
    5156065     I
    5157151     I
    5159930     I
    5171510     I
    5172045     I
    5173333     I
    5173837     I
    5174055     I
    5174065     I
    5174238     I
    5176763     I
    5178176     I
    5179370     I
    5180158     I
    5180210     I
    5180226     I
    5181825     I
    5181960     I
    5183029     I
    5183204     I
    5183480     I
    5183537     I
    5184737     I
    5185161     I
    5185237     I
    5185246     I
    5185295     I
    5185494     I
    5185586     I
    5185615     I
    5185735     I
    5185794     I
    5187512     I
    5188263     I
    5188958     I
    5189203     I
    5189566     I
    5190134     I
    5190228     I
    5190289     I
    5190475     I
    5190558     I
    5192768     I
    5192844     I
    5192862     I
    5192895     I
    5193039     I
    5193127     I
    5193136     I
    5195334     I
    5195361     I
    5195434     I
    5195447     I
    5195475     I
    5195476     I
    5196269     I
    5196303     I
    5196370     I
    5196473     I
    5199903     I
    5200219     E
    5200231     E
    5202026     EAnd I used the same query suggested by you.
    WITH     s     AS(     
    SELECT     se.tserv_id     ,     eu.category     ,
               CASE
                 WHEN     se.performed     BETWEEN     
                                    to_date('&target_dt','DD-MON-RRRR HH24:MI') - (1/24)
                                  AND     to_date('&target_dt','DD-MON-RRRR HH24:MI')
                          THEN     1
              ELSE     0
              END     AS in_hour     ,
            CASE
              WHEN     TRUNC (se.performed - (8/24)) =     TRUNC (to_date('&target_dt','DD-MON-RRRR HH24:MI')
                                                     - (8/24))
                THEN     1
              ELSE     0
              END     AS in_day
    FROM     service_events     se     ,     equipment_uses     eu
    WHERE     eu.gkey          = se.equse_gkey
         AND     eu.category     IN ('I', 'E')
      AND se.tserv_id in ('EXM','GROUNDED')
    SELECT     tserv_id,     
            SUM (DECODE (category, 'I', in_hour))     AS imp_hour,     
            SUM (DECODE (category, 'E', in_hour))     AS exp_hour,
            SUM (in_hour)     AS total_hour,
            SUM (in_day)     AS total_day
    FROM     s
    GROUP BY     tserv_idNow you have the sample data for almost 24 hours
    Let me clear it again
    When I executed this query at 20-JUN-2008 09:00 AM it gives me following result (that is accurate)
    TSERV_ID  IMP_HOUR  EXP_HOUR  TOTAL_HOUR  TOTAL_DAY
    EXM        2         0           2               3
    GROUNDED   1         0           1               8When I executed this query between 20-JUN-2008 00:00 to 20-JUN-2008 08:00
    then system must show the Total_Day value from 19-JUN-2008 08:00 to current date and time. e.g
    I executed this query at 20-JUN-2008 06:00 AM it gives me following result:
    TSERV_ID  IMP_HOUR  EXP_HOUR  TOTAL_HOUR  TOTAL_DAY
    EXM             0     0     0        44
    GROUNDED     2     0     2        35Now here you can see that the value of Total_Day is not as accurate as I required:
    EXM = 44 and GROUNDED = 35
    these values are between 19-JUN-2008 00:00 to 20-JUN-2008 06:00 (that is wrong in my case)
    The values of total_day should be as follows as 8 hours from 00:00 to 07:59 AM fall in the shift of 18-JUN-2008 not in 19-JUN-2008
    From 19-JUN-2008 08:00 to 20-JUN-2008 06:00
    EXM: 38
    GROUNDED: 32
    Plz note that this result is required because in our company the shift starts from 08:00 AM and ends 07:59 AM next day
    I hope you will be more clear now and there is no confusion anymore.
    Plz let me know if you still confused.
    Brgs,

  • Item Transaction History Report - Calculation for creating 'Running Total'

    Hello
    Using Oracle Discoverer, we have written a report that pulls back all Inventory Transactions (by item number). This report lists both transactions IN (e.g. receipts into the store) and OUT (e.g. issues out from the store).
    Our customer would like an additional column, to represent 'Running Total', to be added to the report. This column needs to capture the running 'On Hand Quantity' for the associated Item, as each transaction (both transactions IN and OUT of store) is displayed.
    For example, if the initial/first transaction for an item was a Receipt of 500, then this column (on the first line) should display 500. If the second transaction for the item was an issue of 15, then this column (on the second line) should display 485. If the third transaction was for an issue of 50, then this column (on the third line) should display 435. If the fourth transaction was for a receipt of 20, then this column (on the fourth line) should display 455 etc etc
    I'm not sure how I'd write a calculation to cater for this (within discoverer) - do you know if this is achievable? Any help would be much appreciated. This would be easy enough to do in Excel, but I'm a bit of a novice when it comes to discoverer(!)
    Many thanks
    Ross

    Hi,
    You can generally do this type of calculation using analytic functions. You would partition by the item number and order by the transaction date in the analytic function. You can use SUM function (with an order by) to get a running total of a column in the report. You can SUM a calculation containing a CASE statement which changes the OUT transactions to a negative number. The SUM function will start at zero, so you then can use FIRST_VALUE function to get the first value for the item which you could then add to the totals.
    Rod West

  • Showing  running totals on AR statatement Report

    Hi All I need assistance in populating the Running totals on AR statement Report  , I am trying to calculate the running total on the RDF using the (sum Over Partition ) and Not on the RTF template please assist .
    here is my query below :
    select customers.customer_name,
      detail.customer_id,
      detail.customer_site_use_id,
    :CP_ACC_NAME,
    :CP_ACC_NUM,
    :CP_BRNCH_NAME,
    :CP_COL_EMAIL,
    :CP_COL_PHONE,
    :CP_BRANCH_NR,
    decode(  (select meaning
    from ar_lookups
    where lookup_type = 'INV/CM/ADJ' and lookup_code =  detail.class), 'Payment', apply_date, trx.trx_date)  TRX_DATE,
    trx.INVOICE_CURRENCY_CODE,
    trx.INVOICE_CURRENCY_CODE INVOICE_CURRENCY_CODE_BAL,
    NVL(trx.term_due_date,trx.TRX_DATE)  term_due_date,
    detail.customer_id cst_id,
      detail.customer_site_use_id cst_site_id,
      detail.customer_trx_id,
      detail.trx_number,
       (select meaning
    from ar_lookups
    where lookup_type = 'INV/CM/ADJ' and lookup_code =  detail.class) class,
      detail.amount_full_original,
      detail.end_bal * -1 , (detail.end_bal + detail.amount_full_original)* -1  closing_balance ,
    detail.amount_full_original -  detail.the_order * -1  closing_bal,
      (detail.amount_full_original - detail.running_total) running_total ,
      detail.running_tot ,
      customers.customer_name address1,
      customers.address1 address2,
      customers.address2 address3,
      customers.address3 address4,
      customers.city||' '||customers.state address5,
      customers.country||' '||customers.postal_code address6,
      addr.address1 rm_address1,
      addr.address2 rm_address2,
      addr.address3 rm_address3,
      addr.address4 rm_address4,
      addr.address5 rm_address4,
       :p_as_of_date_from date_from,
       to_char(to_date(:p_as_of_date_to,'DD-MON-YYYY'),'DD-Mon-YYYY') date_to,
      addr.org_id rm_org_id,
       rtrim(to_char(sysdate,'DD')||' '||to_char(sysdate,'Month'))||' '||to_char(sysdate, 'YYYY') curr_date
    from (select customer_id, CUSTOMER_SITE_USE_ID, trx.CUSTOMER_TRX_ID,trx.TRX_NUMBER, null apply_date,ps.class,ps.AMOUNT_DUE_ORIGINAL amount_full_original, the_trx.end_bal,the_trx.running_total , the_trx.running_tot , 1 the_order
    select customer_trx_id, sum(acctd_end_bal) end_bal  , running_total  ,  running_tot
    SELECT ps.customer_trx_id ,
       sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_from))
      * ps.amount_due_remaining) start_bal,
       sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_to))
      * ps.amount_due_remaining) end_bal,
       sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_from))
      * ps.acctd_amount_due_remaining) acctd_start_bal,
       sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_to))
      * ps.acctd_amount_due_remaining) acctd_end_bal ,
       (sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_from))
      * ps.amount_due_remaining) + sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_to))
      * ps.acctd_amount_due_remaining) ) running_total ,  
       sum((sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_from))
      * ps.amount_due_remaining) + sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
       NULL,to_date(:p_as_of_date_to))
      * ps.acctd_amount_due_remaining) )) over (partition by ps.customer_trx_id  order by ps.customer_trx_id)running_tot
       FROM ar_payment_schedules_all ps
       WHERE ps.payment_schedule_id+0 > 0
       --JF2 AND ps.gl_date_closed >= to_date(:p_as_of_date_from)
       AND  ps.class IN ( 'CB', 'CM','DEP','DM','GUAR','INV')
       AND  ps.gl_date  <= to_date(:p_as_of_date_to)
       and org_id = nvl(:P_ORG_ID,org_id)--1246
       --and customer_id = :p_customer_id --1075
       --and CUSTOMER_SITE_USE_ID = :p_customer_site_id --1066
       --and customer_trx_id = 66291
       --'|| l_ps_org_where ||'
       GROUP BY ps.customer_trx_id ,ps.acctd_amount_due_remaining , ps.gl_date,ps.gl_date_closed ,ps.class , rownum 
      ps.customer_trx_id ,
       sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
      ra.gl_date,to_date(:p_as_of_date_from))
      * ( ra.amount_applied  + NVL(ra.earned_discount_taken,0)
       + NVL(ra.unearned_discount_taken,0))) start_bal,
       sum(ar_calc_aging.begin_or_end_bal(ps.gl_date,ps.gl_date_closed,
      ra.gl_date,to_date(:p_as_of_date_to))
      * ( ra.amount_applied  + NVL(ra.earned_discount_taken,0)
       + NVL(ra.unearned_discount_taken

    Hi
    Yes i would like more help as i have never used group by roll up before
    SELECT p.employee_number,
    p.full_name employee_name,
    DECODE (p.sex, 'M', 'Male', 'F', 'Female') gender,
    (DECODE (p.per_information4,
    '01', 'Indian',
    '02', 'African',
    '03', 'Coloured',
    '04', 'White')) race,
    p.original_date_of_hire,
    a.effective_start_date startdate_current_position,
    RTRIM (SUBSTR (ps.NAME, 1, INSTR (ps.NAME, ';')), ';') current_position,
    ho.NAME current_organization,
    xx_return_company_name(a.person_id, a.effective_start_date) current_company,
    RTRIM (SUBSTR (ps1.NAME, 1, INSTR (ps1.NAME, ';')),';') previous_position,
    ho1.NAME previous_organization,
    xx_return_company_name(a1.person_id, a1.effective_start_date) previous_company,
    a1.effective_start_date startdate_prev_position
    FROM per_assignments_v2 a,
    per_assignments_v2 a1,
    per_all_people_f p,
    per_all_positions ps,
    per_all_positions ps1,
    hr_all_organization_units_tl ho,
    hr_all_organization_units_tl ho1
    WHERE a1.person_id = a.person_id
    AND NVL (a1.position_id, 9) <> a.position_id
    AND a1.effective_end_date = a.effective_start_date - 1
    AND p.person_id = a.person_id
    and ho.ORGANIZATION_ID=ps.ORGANIZATION_ID
    and ho1.ORGANIZATION_ID=a1.ORGANIZATION_ID
    AND a.effective_start_date BETWEEN p.effective_start_date AND p.effective_end_date
    AND a.position_id = ps.position_id
    and p.EMPLOYEE_NUMBER not in ('1','2','3')
    AND a1.position_id = ps1.position_id(+)
    order by p.full_name

  • XML 5.6.1 Running Total

    Hi
    I am new this XML Publisher. We are working on using BPA/XML Publisher to print the AR Invoice. I have two questions
    1. How to print the values of subtotal, tax and Invoice Total in only last page
    2. How to print the Running total of extend amount at the end of the each page. This Running total need to be printted once in a Page.
    Thanks
    Mariappan

    Have you placed it outside your group, you just place it at the bottom end of your template and put a group around your sum total.
    Then it it will only be printed on your last page.
    you need a for tag
    ex. <?for-eachG_TAX?>
    Then the sum
    ex. <?sum(current-group()//VAT)?>
    Then the end tag
    ex. <?end for-each?>

  • Running total in report footer returning inaccurate result

    Post Author: smarkta
    CA Forum: Formula
    I am writing a report that contains 3 groups.  I have created running totals for each group that are accurate by selecting the group to evaluate and reset on.  now I need to basically sum the results of the all the group running totals but have had no success.  any tips on how to do this would be greatly appreciated.
    Thanks

    Post Author: Charliy
    CA Forum: Formula
    Were you doing a Distinct Count?  Did you have a formula on the Running Total?  What is there about the Group Totals that make them different than the final total.

  • How do I use a running total within a selection formula?

    I am developing a report within Crystal Reports 2008.  My goal is to identify any accounts that have zero usage for at least six months in this current year.  I have account number, meter size, read date, usage, and a running total/subtotal by account.
    Here is what the data looks like in the report
    ACCTNO     METER SIZE   READ DATE/TIME               READ_USAGE    Counter
    001022-05                    
    001022-05     2.00              9/28/2009  9:42:00 AM      0.00                     1
                                                                                    1
    001110-09               
    001110-09     2.00             3/2/2009  9:54:13 AM         0.00                      1
    001110-09     2.00             3/26/2009  1:32:28 PM        0.00                      1
    001110-09     2.00             4/27/2009  11:02:11 AM     0.00                      1
    001110-09     2.00             5/27/2009  1:13:53 PM        0.00                      1
    001110-09     2.00             6/19/2009  11:41:20 AM     0.00                      1
    001110-09     2.00     9/1/2009  8:13:25 AM         0.00                      1
                                                                                    6
    My report shows all accounts that have zero usage.  I want to filter the report to only show the accounts that have at least six zero usage reads.  I thought I could add a running total, sum it, and filter the data by using the selection formulas.  Unfortunately I keep getting an error message saying "this field cannot be used becuase it is being evaluated later."  Any help would be appreciated.  This is the first report I have created using crystal.
    Edited by: smwdrw2 on Oct 28, 2009 4:29 PM

    You could Conditionally suppress the account numbers where your running total is less than 6
    You will probably have to put your account number summaries in the group footer, instead of the header.
    Then:
    go to the section expert, click on the group footer for the account number, on the right, next to the word "Suppress" click on the box that says "X-2". In the formula put
    IF<6 then True
    Save and close
    The only way this would not work for you is if you have some sort of grand total that you don't want to include the other groups in.

Maybe you are looking for

  • Time limit error no matter what optimization I do...

    Hello Experts, I am trying to optimize the code below since it always results in time limi error when we transport it to production server. I have tried eliminating some select inside the loop and using for all entries but it still gets the error. An

  • Updated to ios6 and now it won't work in the car

    **** - this apple help is really not helping i updated my iphone to the io6 and now it doesn't work in my car.  Why's that?  I tried another iphone with the same problem, it was just updated to io6 and now nothing works ***

  • Crash in OCR--any suggestions for work-around?

    There is a book from Google Books that I want to read on my computer. It's in the public domain, and I downloaded it here. I have OCR'd it using "Searchable Image Exact" in some version of Acrobat (don't remember) so I can do searches in it. But all

  • Finder. Dragging a file into a folder I get inside that folder.

    When dragging a file into a folder I get inside that folder instead of staying in the original location. Why? This may sound a bit stupid but it did not use to happen before and it's annoying when you are cleaning up a folder and just want to drag an

  • CProjects and Sales Order link

    Hi, We are currently using cProjects for the purpose of  Resource allocation. As a part of process, projects are primarily created in SAP and they automatically gets created in cProjects. However, the management has now decided to use it for tracking