How to generate a line in the report to calculate the total?

Hello:

I need help to generate a report. In an accounting report, I need to make the sum for each customer about the outstanding balance. The format of the report is the following:

Invoice #, date of invoice, invoice, amount paid amount paid date, strike, sale

Customer name: Baker Express / name of the debtor: Kurt Weiss inc.

137308001, 18/04/2012, 438.07, 537.07, 05/06/2012, (99)
137308002, 18/04/2012, 10, 100, 90, 05/06/2012

...

customer Total: total payment: 627.07, total outstanding amount: (99)

another pair of customer / debtor
...


My question is how to generate the payment total and total outstanding balancefor each pair of client and the debtor. And there are several pairs. I tried to use Group by, but how do I display each tuple of invoice as well in the report?

Any help would be appreciated.

Sam

One method would be to use the rollup in your SQL
http://www.Oracle-base.com/articles/Misc/rollup-cube-grouping-functions-and-grouping-sets.php

Tags: Database

Similar Questions

  • How to add multiple lines when the button is clicked

    How to add multiple lines when the click on button now is just add a row .plz give me idea how... waiting for answer

    / public final class screen extends MyScreen
    {
    /**
    * Creates a new object of MyScreen
    */
    ObjectChoiceField obj1 obj2, obj3, obj4.
    Table of String() = {'101 ', ' 102'};
    String of shadow [] = {"Shade1", "Shade2"};
    Rolls of string [] = {'101 ', ' 102'};
    String cutting [] = {"100-150", "150-200"};
    Chain of selectedindex1, selectedindex2, selectedindex3, selectedindex4;
    LabelField lbl1 lbl2, lbl3, lbl4;
        
    GFM LinedGridFieldManager;
    HFM HorizontalFieldManager, hfm1, hfm2 hfm3;
    VerticalFieldManager vfmMain;
        
    public MyScreen()
    {
        
    Set the displayed title of the screen
    hfm1 = new HorizontalFieldManager (HorizontalFieldManager.NO_VERTICAL_SCROLL |) HorizontalFieldManager.NO_VERTICAL_SCROLLBAR);
    hfm2 = new HorizontalFieldManager (HorizontalFieldManager.NO_VERTICAL_SCROLL |) HorizontalFieldManager.NO_VERTICAL_SCROLLBAR);
    hfm3 = new HorizontalFieldManager (HorizontalFieldManager.NO_VERTICAL_SCROLL |) HorizontalFieldManager.NO_VERTICAL_SCROLLBAR);
    HFM = new HorizontalFieldManager (HorizontalFieldManager.FIELD_RIGHT);
    vfmMain = new VerticalFieldManager (Manager.NO_VERTICAL_SCROLL |) Manager.NO_HORIZONTAL_SCROLLBAR);
            
    obj1 = new ObjectChoiceField ("", graph, 0, FIELD_LEFT);
    obj2 = new ObjectChoiceField ("", blind, 0, FIELD_LEFT);
    Obj3 = new ObjectChoiceField ("", rolls, 0, FIELD_LEFT);
    Obj4 = new ObjectChoiceField ("", cuts, 0, FIELD_LEFT);
            
    LBL1 = new LabelField("");
    LBL2 = new LabelField("");
    lbl3 = new LabelField("");
    lbl4 = new LabelField("");
            
    ButtonField btnAdd = new ButtonField ("ADD", FIELD_RIGHT);
            
    GFM = new LinedGridFieldManager (4, LinedGridFieldManager.VERTICAL_SCROLL);
            
    hfm1.setMargin (20, 0, 10, 0);
    hfm1. Add (new LabelField ("Chart"));
    hfm1. Add (obj1);
    hfm1. Add (new LabelField ("Shade"));
    hfm1. Add (obj2);
            
    hfm2. Add (new LabelField ("Rolls"));
    hfm2. Add (Obj3);
    hfm2. Add (new LabelField ("Cuts"));
    hfm2. Add (Obj4);
    HFM. Add (btnAdd);
            
    GFM. Add (new LabelField ("Chart"));
    GFM. Add (new LabelField ("Shade"));
    GFM. Add (new LabelField ("Rolls"));
    GFM. Add (new LabelField ("Cuts"));
            
    vfmMain.add (hfm1);
    vfmMain.add (hfm2);
    vfmMain.add (hfm3);
    vfmMain.add (hfm);
    vfmMain.add (new SeparatorField());
    vfmMain.add (gfm);
    Add (vfmMain);
            
    btnAdd.setChangeListener (new FieldChangeListener()
    {
    ' Public Sub fieldChanged (field field, int context) {}
    TODO self-generating method stub
    selectedindex1 = chart [obj1.getSelectedIndex ()];
    selectedindex2 = shade [obj2.getSelectedIndex ()];
    selectedindex3 = rolls [obj3.getSelectedIndex ()];
    selectedindex4 = cuts [obj4.getSelectedIndex ()];
                    
    While (LBL1. GetText(). Equals("") | LBL2. GetText(). Equals("") | lbl3. GetText(). Equals("") | lbl4. GetText(). Equals(""))
    {
    LBL1. SetText (selectedindex1);
    LBL2. SetText (selectedindex2);
    lbl3. SetText (selectedindex3);
    lbl4. SetText (selectedindex4);
                    
    GFM. Add (LBL1);
    GFM. Add (LBL2);
    GFM. Add (lbl3);
    GFM. Add (lbl4);
                    
    }
    }
    });
    }
    }

    Hi Piya,

    I run your code, and according to your logic that it works correctly.

    It's adding that line only once because according to your logic that one line can be added to MDT, if you do not want to add line on each click on the button, follow these steps:

    selectedindex1 = chart [obj1.getSelectedIndex ()];
    selectedindex2 = shade [obj2.getSelectedIndex ()];
    selectedindex3 = rolls [obj3.getSelectedIndex ()];
    selectedindex4 = cuts [obj4.getSelectedIndex ()];

    Lbl1 LabelField = new LabelField("");
    Lbl2 LabelField = new LabelField("");
    LabelField lbl3 = new LabelField("");
    LabelField lbl4 = new LabelField("");
    If (LBL1. GetText(). Equals("") | LBL2. GetText(). Equals("") | lbl3. GetText(). Equals("") | lbl4. GetText(). Equals(""))
    {
    LBL1. SetText (selectedindex1);
    LBL2. SetText (selectedindex2);
    lbl3. SetText (selectedindex3);
    lbl4. SetText (selectedindex4);
                    
    GFM. Add (LBL1);
    GFM. Add (LBL2);
    GFM. Add (lbl3);
    GFM. Add (lbl4);
                    
    }

  • How to add two lines when the second row is not visible, but also gets the first data line too?

    Mr President

    Jdev worm is 12.2.1

    How to add two lines when the second row is not visible, but also gets the first data line too?

    I want to add two lines like below picture, but want the second to remain invisible.

    tworows.png

    I asked this question but my way of asking was wrong, that's why for me once again.

    Concerning

    Try to follow these steps:

    1. in the database table to add the new column "JOIN_COLUMN" and add the new sequence "JOIN_SEQ".

    2. Add this new column in the entity object. (You can add this in entity object by right clicking on the entity object and then select "Synchronize with database" then the new column and press on sync)

    3. in your bookmark create button to create only one line NOT 2 rows.

    4 - Open the object entity--> java--> java class--> on the entity object class generate and Tick tick on the accessors and methods of data manipulation

    5 - Open the generated class to EntityImpl and go to the doDML method and write this code

      protected void doDML(int operation, TransactionEvent e)
      {
        if(operation == DML_INSERT)
        {
          SequenceImpl seq = new SequenceImpl("JOIN_SEQ", getDBTransaction());
          oracle.jbo.domain.Number seqValue = seq.getSequenceNumber();
          setJoinColumn(seqValue);
          insertSecondRowInDatabase(getAttribute1(), getAttribute2(), getAttribute3(), getJoinColumn());
        }
    
        if(operation == DML_UPDATE)
        {
          updateSecondRowInDatabase(getAttribute1(), getAttribute2(), getAttribute3(), getJoinColumn());
        }
    
        super.doDML(operation, e);
      }
    
      private void insertSecondRowInDatabase(Object value1, Object value2, Object value3, Object joinColumn)
      {
        PreparedStatement stat = null;
        try
        {
          String sql = "Insert into table_name (COLUMN_1,COLUMN_2,COLUMN_3,JOIN_COLUMN, HIDDEN_COLUMN) values ('" + value1 + "','" + value2 + "','" + value3 + "','" + joinColumn + "', 1)";
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
      private void updateSecondRowInDatabase(Object value1, Object value2, Object value3, Object joinColumn)
      {
        PreparedStatement stat = null;
        try
        {
          String sql = "update table_name set column_1='" + value1 + "', column_2='" + value2 + "', column_3='" + value3 + "' where JOIN_COLUMN='" + joinColumn + "'";
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
  • How to animate a line with the pen tool to give the impression that it is plotted?

    How to animate a line with the pen tool to give the impression that it is plotted?

    Or you can choose the pen tool (g), set the padding to zero and the race to what you want, then draw a path, then press U twice to reveal all of the properties that have been changed for the layer, and then click Add (top-right) and select Connect the tracks.

    To make the race work just animate the start or end point and sent to paint on original or reveal original or normal.

  • How do a straight line of the curve?

    Hello

    I wonder how to move a line to the right a little bit without erasing anything.  How can I move on a bit?  The area that surrounds it may curve a little with it.

    Thank you

    Looks like you could had to use liquefy to move the line, or deformation of the puppet or perspective distortion. Several ways to edit an image and it is difficult to say without seeing a screen shot.

  • How to jump/remove line under the name of report

    Hello

    How to remove the line under the name of report

    Thank you

    Hello

    Change the display of the title and goto Format title view just about symbol brush that is above the word title
    Border-> Position-> none

    Thank you
    Oldia...

  • Can PCI 6602:How I use digital lines of the Board of Directors and at the same time to generate trains of pulses by using a meter?

    Hello!

    My problem appeared when I tried to update my traditional NOR-DAQ legacy code to DAQmx.

    I use 2 meter (meter 5 and 7 meter) on PCI-6602, to generate trains of pulses, as well as the lines of e/s digital port 0 (the form lines from 0 to 7). What I do in my request, it's that I'm starting to generate the pulse train on the output of 2 meters and after that I play with the State of digital lines.

    Traditional, it was no problem to use the meters and digital lines at the same time, everything went perfectly, but in DAQmx, is not possible.

    What's happening: I start generating train of pulses on the output of counters, no errors, but when I try to change the State of a line of digital port the generation of the pulse train is stopped. What happens when I start the task associated with the digital way.

    My question is: is it possible to create a channel on digital lines without changing the channels created for meters?

    Another thing that I managed to do with the panels 'Measurement and Automation Explorer' and Test for PCI-6602, is basically the same thing, I generate trains of pulses on the output of the 7 meter and try to start a job on the digital line, but I get an error:

    "Error-200022 occurred in test Panel.
    Possible reasons:
    Measurements: Resource requested by this task has already been reserved by another task.
    Device: Dev4
    "Terminal: PFI8.

    On the contrary if I use the counter 0 or a counter 1 to generate trains of pulses I encounter the same problem.

    What resources are used by 2 to 7 of the PCI-6602 card counters and the counters to 0 and 1 do not use?

    Thanks in advance for any answer!

    Ciprian

    After doing some real tests on this device, I found that it is a normal behavior for the jury of 6602.  This is because when you start a task digital all 32 lines are configured for digital i/o, so it replaces your meter operation.  The article below the link explains a little more on this subject.  You must start the digital task before the task of counter to use the features of both in your program.

    2 meter and above will not work correctly when you perform digital i/o on NI 6601 or 6602

    http://digital.NI.com/public.nsf/allkb/43F71527765EEC3886256E93006CD00C?OpenDocument

  • How to generate a trigger when the arbitrary

    Hi all

    I have a digital output pci card 6534 and an analog output pci card 6723.

    I would like to generate a material long pulse sequence timed. The 6534 has 32 MB memory on board, so it is good to do a long sequence. The 6723 will run out of memory if started at the same time. I would therefore trigger the 6723 at a later date. The boards are connected with rtsi.

    I see 3 ways to do (well that I know how to do, but the first two would be more elegant):

    (1) generate a sequence of digital pulses on ports (i.e. how that), then convert a line of port online rtsi (don't know how to)?

    (2) generate a trigger to the arbitrary point on the rtsi lines (don't know how to)?

    Go 3) with 1) physically connecting a port to a line PFI on the analog card.

    I have not found a way to send a trigger at some arbitrary point with the RTSI. Instead of this I went with solution 3) and related digital outputs analog card PFI channels.

  • How to generate a pulse with the signal generator?

    Hello

    I would like to ask if anyone knows how to use the Elvis platform to generate a regulated pulse wave?

    It should look roughly like the picture above. A sine wave with the regulation.

    Anyone who can answer my question please respond to my post.

    Thank you.

    You are using LabVIEW to generate the waveform or using the Soft front panels? In LabVIEW, you can use the express VI generator function and specify the Type as "Sine". Then, simply change the amplitude of the sine wave. During the actual pulse, the amplitude would be what you want (i.e. 1 V) and while the pulse is idle, set the amplitude to 0.

    If you use the soft front panels, you can use the Waveform Editor to create a waveform that includes a sine wave for the length of your pulse and then the values of '0' for the rest of the time. Then use this waveform in the flexible front of the arbitrary signal generator. Simply create a component of sine as the first part of the wave and then add another element to a level DC '0' for the rest.

  • Question: how to format multiple lines in the Guild: email field

    Hello

    I would like to have a message of several lines in the body of the email. I can get the text to include, but all in a single line. How can I get the lines to be separated into several separate lines? Everything except the formatting of the message works very well. Here's my script, which does not work:

    app.mailMsg ({}

    bUI: false,

    cTo:

              cCc: " includedaccounting@fheg. Follett.com ; ", "

    bassujetti: 'True full up' + "" + page1.storeInfo.arMajor.rawValue + "" + pages1_3.page1.storeInfo.storeNum.rawValue,.

    CMSG: 'Hello,';

    + 'The true for this store was completed. Please find the links to the list control and reconciliation below. \n » ;

    + "Checklist: \n";

    + ' Reconciliation: \n ";

    + "Thank you, \n";

    }}}}});

    Thank you

    MDawn

    Hello

    It seems that you may have a few errors of syntax... or is the forum scrap things up.  You do not want any semicolons in the argument mailMsg() and you used all the accolades.  Something like;

    app.mailMsg ({}

    bUI: false,

    cTo:

    cCc: "[email protected];"

    bassujetti: 'True full up' + "" + page1.storeInfo.arMajor.rawValue + "" + pages1_3.page1.storeInfo.storeNum.rawValue,.

    CMSG: 'Hello '

    + 'The true for this store was completed. Please find the links to the list control and reconciliation below. \n ".

    + "Checklist: \n".

    + ' Reconciliation: \n ".

    + "Thank you, \n".

    });

    Concerning

    Bruce

  • How to generate Java classes during the generation of the WebService Datacontrols?

    Hello

    I use data controls generated by the web service in my application, but I am stuck at a point where I got a requirement to create a Java bean for the complex type. There's no java class created when we create data controls using the web service.

    I need to grasp the object of return type of a method of data control (example: I need to capture the Department object that is returned by the getDetartment method) to validate the data.

    The XML files are created in the template while creating web service data controls. How to generate java classes out of it?

    Please can someone help out of this?

    I hope you understand my question.

    Please let me know if you want more details about me.

    Thanks and greetings
    Thoom

    Hello

    If this is your condition using a WS client proxy class and create a POJO to data control (right click). The WS data control generates classes and uses instead of XML schema definitions

    See example at http://www.oracle.com/technetwork/developer-tools/adf/learnmore/index-101235.html 073

    Frank

  • How to draw a line under the first paragraph

    Hello

    I am trying to solve a problem: my text field should be divided into two parts, horizontally. First part is intended for a log book, and the second is for the body. I need to divide them visually tracing a line between them. The logic is to take the first paragraph and make a summary. The rest is the body. So I need to be able to get the height of the first paragraph in order to draw the line at the right position. And I will have to adjust its position whenever the user scrolls the text.

    Any ideas how to on this subject?

    see you soon,

    Jan

    There is a discussion about the various ways to do it in this thread:

    http://forums.Adobe.com/message/3382440#3382440

    You will also find the recent message on the blog useful:

    http://blogs.Adobe.com/tlf/2011/01/decoration-example.html

    -robin

  • How to put a line inside the foreach loop number

    Hello

    I work in a nutshell, model, and I have a foreach loop. For each row of data, I would like to put a line at the beginning of the line number, i.e., 1,2,3,4, etc.

    How can I do this in Word?

    Thank you

    use

    
    
    
  • How to remove a line in the database

    Hello

    I want to remove a line in the database... I used the (drag and drop the data control), delete operation when I push the button in the page it removes just in the session not on the database,

    This means that when I reload the session or I check line in the database, that I always find...

    I use jdeveloper 12.1.3.0.0 and business components.

    You must press the validate after the delete operation (from data controls drag / move validation operation).

    If you want to run Remove and validate the operation in a single action, in your page, you can add the button and in the action of the button write this code:

      public String DeleteAction()
      {
        OperationBinding operationBinding = BindingContext.getCurrent().getCurrentBindingsEntry().getOperationBinding("Delete");
        operationBinding.execute();
    
        operationBinding = BindingContext.getCurrent().getCurrentBindingsEntry().getOperationBinding("Commit");
        operationBinding.execute();
    
        return null;
      }
    

    Make sure that the "Delete" operation point to the desired pageDef VO. and don't forget that "Commit" operation existence in pageDef.

  • How to draw a line (with the line segment tool) then draw another line, from those previous anchor point. When I try immediately draw another line on the other anchor lines it try to turn instead.

    I'm following a course of basic fundamental illustrator on Lynda. The video of "draw straight lines" is troubling me. They draw a line with the line segment and then draw another line coming out the anchor point at an angle.

    Here's where it is troubling me - when I try to drag a line to the anchor point trying to transform the first line, I drew. (the line cursor turns into a selection tool) I can't draw another line connecting the first.

    Advice would be great because it's driving crazy me.

    See you soon,.
    Kyle

    Yes, it is irritating. You must clear the previous line first. If you want to make sure that both ends are perfectly aligned, start by turning on the guides. If you want two lines to be part of the same way, you should use the tool pen instead.

Maybe you are looking for

  • Error (-50)

    Hello I have always have an error (-50) when I try to connect to my ITUNES Store account, you have an explanation for me? Thank you

  • AppleTV and purchased TV shows

    I have an AppleTV 4th gen has recently discontinued showing all the tv shows that I have purchased through iTunes.  The strange thing is that all my purchased movies and music appear.  So far, I have tried the following troubleshooting steps: 1 reboo

  • INITIALIZE A HP LJ P1102W HD

    someone at - it the procedure to do this or reset the default settings from the factory would also help? Thank you POLO33

  • Section of remote desktop connection has been disconnected due to the protocol error

    I used Windows 7. I first run the Windows Firewall with advanced security. Then I run Remote Desktop connection. He began to load (as many times before) and then all of a sudden has generated a message from remote desktop connection "because of a pro

  • Update video driver to 100 PC in remote network

    Video driver needs to be updated about 100 machines on my university network. Dell Optiplex built with Windows 7. I would like to know if this could be done remotely to save administrators logging in each machine and manually update the driver?