PivotTable with header in two rows

Hello
is it possible to split a large pivot table to the narrower PivotTable with two heads?

I need to achieve this result: [http://img30.imageshack.us/img30/2339/oraclebipivotmultiplehe.jpg]

Column with total didn't need to be formatted as it is on the screenshot. But for me it is important to split a long pivot table two rows header...

Thank you

I have the solution. I have transformed an original table with clean function js and jQuery

function transformPivotTable (tableId) {}
var $tables = $("#" + tableId + "table.) Pivot table");
               
If ($tables.length == 1 & $tables.attr("id").substr (0.3) == 'vu') {}
                                        
var $table = $tables;
var $headings1 = $table.find ("tr:eq (0) td:lt (11)");
var $headings2 = $table.find ("tr:eq (0) td:gt (10)");
var $values1 = $table.find ("tr:eq (1) td:lt (11)");
var $values2 = $table.find ("tr:eq (1) td:gt (10)");
               
$table.find ("tr:eq (0)") .html ($headings1);
$table.find ("tr:eq (1)") .html ($values1);
               
var $newrowHeadings = $(')") .addClass ("PTRowLabelsRow");
var $newrowValues = $(')");
               
$newrowHeadings.html ($headings2);
$newrowValues.html ($values2);
               
$table.append ($newrowHeadings);
$table.append ($newrowValues);
               
}
               
}

This function can be performed by button or after the page loads:

transformPivotTable('d\\:dashboard\\~p\\:0fbi1pfhhtepur3d\\~s\\:vpjrrqes9j4sbo2kContents');

' d\\:dashboard\\ ~ p\\:0fbi1pfhhtepur3d\\ ~ s\\:vpjrrqes9j4sbo2kContents' is ID to lock up the HTML table with escape characters. It was the final table with ID fixed. Other nested tables had dynamic IDs, so I had to go with fixed ID and my PivotTable to search for the attribute class.

Tags: Business Intelligence

Similar Questions

  • Mr President, how can I enter two rows at the same time with different default values that only the first line to use see?

    Mr President.

    My worm jdev is 12.2.1

    How to enter two rows at the same time with different default values that only the first line to use see?

    Suppose I have a table with four fields as below

    "DEBIT" VARCHAR2(7) , 
      "DRNAME" VARCHAR2(50),
      "CREDIT" VARCHAR2(7) , 
      "CRNAME" VARCHAR2(50),
    

    Now I want that when I click on a button (create an insert) to create the first line with the default values below

    firstrow.png

    So if I click on the button and then validate the second row with different values is also inserted on commit.

    The value of the second row are like the picture below

    tworows.png

    But the second row should be invisible. It could be achieved by adding vc in the vo.

    The difficult part in my question is therefore, to add the second row with the new default values.

    Because I already added default values in the first row.

    Now how to add second time default values.

    Concerning

    Mr President

    I change the code given by expensive Sameh Nassar and get my results.

    Thanks once again dear Sameh Nassar .

    My code to get my goal is

    First line of code is

        protected void doDML(int operation, TransactionEvent e) {    
    
            if(operation != DML_DELETE)
                 {
                     setAmount(getPurqty().multiply(getUnitpurprice()));
                 } 
    
            if (operation == DML_INSERT )
                       {
                               System.out.println("I am in Insert with vid= " + getVid());
                           insertSecondRowInDatabase(getVid(),getLineitem(),"6010010","SALES TAX PAYABLE",
                            (getPurqty().multiply(getUnitpurprice()).multiply(getStaxrate())).divide(100));      
    
                           }
    
            if(operation == DML_UPDATE)
                              {                                                    
    
                                 System.out.println("I am in Update with vid= " + getVid());
                             updateSecondRowInDatabase(getVid(),
                                 (getPurqty().multiply(getUnitpurprice()).multiply(getStaxrate())).divide(100));      
    
                              }                      
    
            super.doDML(operation, e);
        }
        private void insertSecondRowInDatabase(Object value1, Object value2, Object value3, Object value4, Object value5)
                  {
                    PreparedStatement stat = null;
                    try
                    {
                      String sql = "Insert into vdet (VID,LINEITEM,DEBIT,DRNAME,AMOUNT) values " +
                 "('" + value1 + "','" + value2 + "','" + value3 + "','" + value4 + "','" + value5 + "')";  
    
                      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 value5)
                  {
                    PreparedStatement stat = null;
                    try
                    {
                      String sql = "update vdet set  AMOUNT='"+ value5+"' where VID='" + value1 + "'";                     
    
                      stat = getDBTransaction().createPreparedStatement(sql, 1);  
    
                      stat.executeUpdate();
                    }
                    catch (Exception e)
                    {
                      e.printStackTrace();
                    }
                    finally
                    {
                      try
                      {
                        stat.close();
                      }
                      catch (Exception e)
                      {
                        e.printStackTrace();
                      }
                    }                  
    
                  }
    

    Second line code is inside a bean method

        public void addNewPurchaseVoucher(ActionEvent actionEvent) {
            // Add event code here...
    
            BindingContainer bindings = BindingContext.getCurrent().getCurrentBindingsEntry();
                   DCIteratorBinding dciter = (DCIteratorBinding) bindings.get("VoucherView1Iterator");
                   RowSetIterator rsi = dciter.getRowSetIterator();
                   Row lastRow = rsi.last();
                   int lastRowIndex = rsi.getRangeIndexOf(lastRow);
                   Row newRow = rsi.createRow();
                   newRow.setNewRowState(Row.STATUS_NEW);
                   rsi.insertRowAtRangeIndex(lastRowIndex +1, newRow);
                   rsi.setCurrentRow(newRow);
    
                   BindingContainer bindings1 = BindingContext.getCurrent().getCurrentBindingsEntry();
                   DCIteratorBinding dciter1 = (DCIteratorBinding) bindings1.get("VdetView1Iterator");
                   RowSetIterator rsi1 = dciter1.getRowSetIterator();
                   Row lastRow1 = rsi1.last();
                   int lastRowIndex1 = rsi1.getRangeIndexOf(lastRow1);
                   Row newRow1 = rsi1.createRow();
                   newRow1.setNewRowState(Row.STATUS_NEW);
                   rsi1.insertRowAtRangeIndex(lastRowIndex1 +1, newRow1);
                   rsi1.setCurrentRow(newRow1);
        }
    

    And final saveUpdate method is

        public void saveUpdateButton(ActionEvent actionEvent) {
            // Add event code here...
    
            BindingContainer bindingsBC = BindingContext.getCurrent().getCurrentBindingsEntry();      
    
                   OperationBinding commit = bindingsBC.getOperationBinding("Commit");
                   commit.execute(); 
    
            OperationBinding operationBinding = BindingContext.getCurrent().getCurrentBindingsEntry().getOperationBinding("Commit");
            operationBinding.execute();
            DCIteratorBinding iter = (DCIteratorBinding) BindingContext.getCurrent().getCurrentBindingsEntry().get("VdetView1Iterator");// write iterator name from pageDef.
            iter.getViewObject().executeQuery();  
    
        }
    

    Thanks for all the cooperation to obtain the desired results.

    Concerning

  • Remove ' / ' with a value of feld to create two rows

    I have a table with a structure like

    CREATE TABLE TEST
    (
    MOLDCODE VARCHAR2 (20 BYTE) NOT NULL ACTIVATE.
    PRODCODE VARCHAR2 (255 BYTE),
    DIAMCONTAINER NUMBER (4.1).
    SEGMENT NUMBER (2.0)
    )

    And it contains data such as

    MOLDCODE PRODCODE DIAMCONTAINER SEGMENT

    ADE16920-1 CJ02A/SD51A 96 10
    ADE20206 CT25A 95 8
    ADE16912-1 DG31A 57 10
    ADE16913 AS30A/DE28A 96 10
    ADE17845 CJ24A/SD36A 96 10


    I want to create another table saw which will remove / of prodcode and he will separate the values and forms two rows with the same values for the other fields.
    for example.

    Source: -.
    MOLDCODE PRODCODE DIAMCONTAINER SEGMENT

    ADE16920-1 CJ02A/SD51A 96 10
    ADE16913 AS30A/DE28A 96 10

    Purpose: -.
    MOLDCODE PRODCODE DIAMCONTAINER SEGMENT

    ADE16920-1 96 10 CJ02A
    ADE16920-1 96 10 SD51A
    ADE16913 AS30A 96 10
    ADE16913 DE28A 96 10

    Is it possible?
    Need help for the same thing.

    Check this box:

        SELECT moldcode,
               REGEXP_SUBSTR (procode,
                              '[^/]+',
                              1,
                              LEVEL)
                  procode,
               diamcontainer,
               segment
          FROM t
    CONNECT BY     LEVEL <= REGEXP_COUNT (procode, '/') + 1
               AND moldcode = PRIOR moldcode
               AND PRIOR SYS_GUID () IS NOT NULL;
    

    See you soon,.
    Manik.

  • two rows of back with a single column with just one place

    Hello all;
    I have a query that returns two rows similar to this below
    
    ID      PLACE            PROGRAM
    A       NEWYORK      PROGRAM A
    A       NEWYORK      PROGRAM B
    
    I would like this instead
    
    ID      PLACE             PROGRAM
    A       NEWYORK       PROGRAM A
                                   PROGRAM  B
    
    All help is appreciated. Thank you.
    Published by: user13328581 on March 22, 2011 11:52

    user13328581 wrote:
    WOW... Thanks a lot for Salomon, I never used the partitions and row_number in such a way... can you please explain your logic.

    Ensure that:

    ROW_NUMBER() over (partition by order of identification by location, program)

    This operation can take all the rows returned by the query andsplit them in compartments (sheet music) by id. Inside each bucket it order lines by program and place and assign line numbers. So for each row of the ID number 1 will be stored with (in alphabetical order) first place the first programt. And this is the line where we want to ID is displayed. That's why we wrap the analytical function that precedes in the CASE statement that will do just that. Now:

    ROW_NUMBER() over (partition by id, order by program)

    pretty much the same just bucket is a combination ID / PLACE. So for each combination of it, we want to show that for the first (in alphabetical order) programt.

    Now notice in the ORDER BY clause I prefix ID and PLACE with the table alias. You do it because otherwise the query alias ID and PLACE will have priority resulting in the incorrect sort order (remember that we cancelled all ID and PLACE with the exception of the number of line 1).

    SY.

  • How can I move App Tabs down, where are the other bookmark toolbars? Or, how can I put my toolbars on two rows bookmarks and forget the App Tabs?

    I have several bookmarks in my toolbar, and my most often used found in a drop down menu, which is annoying. I have tried to click and drag on the menu bar, there was room for more icons, but they didn't budge. Anything under the "toolbar" has been helpful. Help tell me do right click on my toolbar and then click on 'Customize'... which did not come as an option. I would like to really all my favorites toolbar (I have about 10) or real on the toolbar visible, not hidden in a small dropdown tab menu.
    There is a plug-in that allows you to put bookmarks in two rows on your toolbars, but it is not compatible with my version of FF (7.0.1).
    App Tabs are cute, but I don't like them on top where they take place where I have the legs for various open websites (I usually opened several at once). App Tabs are fixed and do not move as site tabs, which is extremely annoying and so why I 1) want to move to the bottom of the toolbar or 2) be able to view all my bookmarks toolbars - which is what I prefer.
    BTW, I have Windows 7.
    Thanks in advance for your help.

    App tabs are special tablets and are always displayed at the left end of the tab bar.

    You can place all the bookmarks that you want to see the toolbar of bookmarks in the bookmarks toolbar folder.

    You can do this in the sidebar or the Manager of bookmarks if you can't do it on the bookmarks toolbar.

    Most visited is a special file (smart) which shows the websites that you have visited and are not necessarily Favorites, so you can not drag on the personal bar unless you first to bookmark the. You can make it open in a tab by clicking on Star on location bar twice and choose the toolbar of bookmarks as destination folder.

  • text file with header data

    Hello

    for my test application, I want to store test data in a text file with header. It should be like this:

    name, series, count, current, min. Max run

    Mister Smith

    1234567890

    111

    10

    1000

    data:

    1 345 34

    2 355 23

    3 360 34

    ...

    The first row are only on the lines of header information. ' data: ' is the beginning of the data marker. The data consists of a number, the average value of the current regulation time in s.

    Now I write an array of strings in the file text, but if the length of the header of Exchange I overwrite the data. For example, the name is Mister John Smith.

    In my program, I can create a new file with header and I cannot change the header later. In the routine of the measure, I put the data in the file.

    How can I solve this?

    Thank you

    Schwede

    Hallo Schwede,

    Here is an example:

    Carefule and do a few checks, at this time, it will reduce 'your comments' when it exceeds 512 bytes...

  • Concatenate two rows

    Hello

    I have a requirement where to check a table with a list of values in reference data.

    I get two rows with a column for each output that every time and I need to concatenate the two rows in a field.

    Is there any combination/processor that can be used to do this?

    I tried concatenate / merge and merge data from processors without success.

    Any direction is much appreciated.

    Thank you

    SID

    It is not clear what criteria do you use to determine which records to eat together. The research is not relevant?

    If it's all the records that spent searching you need to eat, it's simple, you can just add a grouping key (for example to add string to a value of 1 attribute), and then group and merge, creating a merged with output value ' delimited list by a "which is used to create the string.

  • Difference between two rows in a table.

    Hi all

    I have a requirement where I need to calculate the difference of a column, but the values are in two rows.

    Its exactly like that, I'll have a table where I have stored incidents with their status and their modification dates

    example:
    Incident_Id: Status: Modified_Date (in seconds from a specific date)
    1: 1: 9080890
    1: 2: 9080999
    1: 3: 9081900
    2: 1: 10000900
    2: 2: 10001000
    2: 3: 10002000

    Now there I show the time spent by each incident in each State.

    That is to say for the State 1 I need the difference between the date of change of condition 2 and updated the date of status 1 Similarly

    2 necessary status the difference between the date of change of condition 3 and updated the status date 2 and so on.

    the real result, I need is like that

    Incident_Id: Status: Timespent
    1: 1: (modified_date (status2) - modified_date (status1))


    Please help me to write the query to do this.

    Kind regards
    Tauceef

    Can we assume that the lines are classified according TO the event status ?
    This (i.e. an Ordering) is necessary in order to systematically identify consecutive lines.

    Please try the analytical function LAG and less to the current value.

  • What controls the space above "maincontent" in CSS layout with header?

    In a page layout CSS freshly downloaded with header (twoColHybLtHdr or similar), there is a space of subject 20px from the bottom of the header area to the top of the box maincontent.   For this reason of space, when a bottom border is added to the header and a left edging maincontent, two lines don't intersect, which is what I want.  What controls this space so I can get rid of him?

    Thank you, Joann

    Hi Joann,

    Add this to your CSS and it will consolidate the gaps for you.

    / * put the parameters of the default browser on all zero * /.

    * {margin: 0; padding: 0; line-height: 100%; do-size: 100 %}}

    Then manually add some top of the margin, margin-bottom, padding and line-height to your different selectors: h1, h2, h3, p, ul, ol, li, li, etc...

    Good luck

    Nancy O.
    ALT-Web Design & Publishing
    Web | Graphics | Print | Media specialists
    http://ALT-Web.com/
    http://Twitter.com/ALTWEB
    http://ALT-Web.blogspot.com

  • HP Laserjet P1102: Two rows of black dots on every print

    I recently removed the seals and tested a few impressions, but each of them contains two rows of black dots on the left side (a line more fat and other points more small rank). I did the cleaning print but no use. Here are some pictures of the question. I can print any document, but the points are the problem. I run on the genuine laser HP cartridge by default. Also, the points are spaced the same way.  Any help would be appreciated...

    No! The load inside the cartridge is bad

  • Is it possible to load your phone with the Office using the cord with head phone the ends of both sides?

    Is it possible to load your phone with the Office using the cord with head phone the ends of both sides?

    No, only USB.

    Taken head phones don't have any power.

  • Its mixed? While playing the slide with audio, if the customer has hit a tab with audio interaction, two sounds will play together. How to avoid what is happening?

    While playing the slide with audio, if the customer has hit a tab with audio interaction, two sounds play together, which is not a good customer experience.

    How to avoid what is happening? Placing a marker can help, but cannot solve the problem when the compliant/no intentional user, press tab.


    Better, if the presenter can triggle tab automatically at some point, or click interaction, no game bar function.

    Hi Louie,

    My sincere apologies for not being able to help on your previous question.

    Now, that the Interactions are concerned, they were initially designed to be placed as standalone content on the slide.

    Also if you try to resize your interaction and place it on the slide as well as other content/objects released published will always give a priority to the Interaction that it deemed to be a specific slide of Interaction.

    In the previous project, you shared, you try to time the Interaction with PowerPoint animations and wanted it to appear later on the set of slides, rather than on the start. But, as explained above, presenter honored not this setting in your project, because he in fact has considered a slide of interaction and display interaction since the beginning of the slide room itself.

    Also the number listed in this thread is concerned, there is no direct way to do it but I would like to suggest something that might help.

    If you want to keep the interaction on your slide and other content, Interaction will be available at the beginning of the slide. Surely there is no way that delaying his appearance, but you can still use animation related to Interaction in another goal. Within your presentation-> playback option settings, you can enable the feature of 'Pause after each animation' (see screenshot below). It will essentially help you achieve the function of auto-faisant a break from your animations, using your narration would automatically stop, just before you claim in your narrative and inform the learner to click on the different tabs of the Interaction. All you have to do is your narration and animation correctly so that the slide play does not break too many times in the time interval. Hope you find the idea of what I'm trying to say.

    Please mark this answer as being correct, if you find it useful. We would certainly look at such scenarios to be achievable directly at the request of our updates and later version.

    Thank you

    Zeeshan Hussain

    Adobe Presenter Engineering Team

  • Compare two rows in the same table

    Hi all

    I need to compare two rows in the same table, I don't know hoe to do it in pl/sql. Please help me on this.

    example:

    price of ro TR
    xya0001 AMA.7 12
    xya0003 ama6 14
    xya0004 AMA.7 16

    in table b is a unique value for each line, I need to compare the price column and see if the first value is less than or greater than the following value and, if there is more to put the corresponding value of br to a variable, and if it is less, put the corresponding value of the br to another variable. I don't know a method to do this, as I'm new to pl/sql. Please help me in this
    for data in(select tr,br,price, lag(price) over ( order by tr) newcol
    from yourtable)
    loop
    if nvl(data.newcol,0) > data.price then
    variable1:=data.br;
    else
    varable2:=data.br;
    end if;
    end loop;
    
  • Max returns two rows

    select BOND_SCHED_ID,bond_id,earnings_proceeds,max(s.effective_date) as effective_date
    from XXDL.xxdl_cd_bond_schedk_p2b  s
    Group by BOND_SCHED_ID,bond_id,earnings_proceeds
    Table has two rows it returns two rows. I need to have a single folder
    Actual
    
    10020     7     200     01-FEB-11
    10000     7     100     01-JAN-11
    
    Expected
    10020     7     200     01-FEB-11
    What is the best application I can write

    893185 wrote:

    Table has two rows it returns two rows. I need to have a single folder

    According to what criteria? I'll assume last effective_date for the connection id. If so:

    select  bond_sched_id,
            bond_id,
            effective_date
      from  (
             select  s.*,
                     row_number() over(partition by bond_id order by effective_date desc) rn
               from  XXDL.xxdl_cd_bond_schedk_p2b s
            )
      where rn = 1
    /
    

    SY.

  • Using Sections to tie together the two rows

    I use the ability of the section to bring together two rows.  I have a button that will duplicate the section.  On the screen shows perfectly.  However, when you save the file, open it back up it does not keep these articles.  It groups them into one.  Look at this example:

    TABLE 1

    RANK 1: Item1, item2 - line 1 & 2 are the group as section

    2nd ROW: Item1, item2

    User, press the Add button:

    Table 1

    1st ROW: Item1, item2 - so when the user presses the Add button it duplicates the section to add more than two lines in order

    Row2: item 1, item2

    ROW3: 1 item, item2

    ROW4: item 1, item2

    The moment user saves the form and exit...

    The user lanuches drive and opens the form. they see the result to follow...

    ROW1: Item1, item2

    ROW3: Item1, item2

    Row2: Item1, item2

    ROW4: Item1, item2

    I need the section to stay together...  Any suggestions of what can be done?

    Concerning

    Uncheck the box for "repeat row for each data item" tab Bidning Row2, and Row3 inside the Section.

    You actually create a new instance of the section (including Row2, and Row3). If this check box must be checked in the Section levl not at the level of the line. You have already checked the property Section so remove from the ranks 2 and Row3.

    Thank you

    Srini

Maybe you are looking for