sum of a column of the dimension

Hello
If my requirement of report said we get SUM (Treasury of column) of the dimension table then can we do it? I have undersatnd that function must be used for measures in fact table. What are we doing to reach the sum of the columns in the dimension table? The report tries to compare the sum (column done) sum (dimension columns). Earlier when I used the sum on the column dimension function he gave no precise results. Please advice.

Unfortunately, I could not explain this matter in a simple unique way, without seeing exactly the report and generated queries

In the simple table, OBIEE is supposed to do something like this (I assume you put the attribute of the year, money and a measure of 'real')

"+ select +".
+ Year +.
+ Sum (cash) +.
+ Sum (fact measure) +.

+ Of +.
+ time_dim_table, +.
+ cash_dim_table, +.
+ fact_table +.

+ where (joins).
+ Group by year +.
"

You can check if the physical demand looks like this, in order to understand the results.

In the PivotTable, it's totally different.
Your physical demand will be no aggregation: so what will:

"+ select +".
+ Year +.
+ Cash +.
+ Sum (fact measure) +.

+ Of +.
+ time_dim_table, +.
+ cash_dim_table, +.
+ fact_table +.

+ where (joins).
+ Group by year, money +.
"

But, OBIEE then apply logic calculatiosn to display goods results in the PivotTable.
Who can explain the different results.

But don't forget that told you right: avoid the aggregation on the dimension attributes. You can sometimes has good results (ex: using the pivot, or other), but it's not really the best way to make your reports. If you often need a "sum (cash"), create a new table of logic made with the 'picture of cash' (even if it is also a dimension table).

Tags: Business Intelligence

Similar Questions

  • Made with multi date columns to the dimension of time

    Hello world

    First let see my script:

    I have the control panel with these columns

    order_no (int),

    create_date (date),

    approve_date (date)

    close_Date (date)

    ----

    I have a time hierarchy dimension: time

    I want to see at the time of the hierarchy, how many orders created, approved and closed for each time part(year,quarter,month,..) as below:

    Date | created | approved | closed

    ————————————————------------------------

    2007-1st quarter | 50. 40         | 30

    2007 - q2 | 60. 20         | 10

    Q3-2007 | 10. 14         | 11

    2007-4th quarter | 67. 28         | 22

    Q1-2008 | 20. 13         | 8

    Q2-2008 | 55. 25         | 20

    Q3-2008 | 75. 35         | 20

    Q4-2008 | 90. 20         | 2

    My solution:

    Physical layer;

    1. I create an order f alias as the fact table for the roll of the order

    2 i joined f-ordered with d-time (time alias) on f_order.created_Date = d - time.day_id

    3 - I added 2 logical column with the formula of the measures:

    Sum aggregation is_approved(If approve_date= THEN 0 else 1)

    Sum aggregation is_closed(If closed_date= THEN 0 else 1)

    order_no (will use to measure aggregation created County

    When I create the report in analytics in the generated query he used created_date and this isn't what I expected!

    What is the best solution?

    1-

    If I have to create 3 is of the order: f_order_created, f_order_approved, f_order_closed and join each other on these columns d-time?

    f_order_created.created_Date = d - time.day_id

    f_order_approved.approved_Date = d - time.day_id

    f_order_closed.closed_Date = d - time.day_id

    2-do you create my fine measure?

    Hello anonymous user,.

    The approach with three done alias that you then use in three separate sources of logical table for your logical fact is the right one. This way, you keep canonical once and did do the role play.

    So you won't need to 3 facts in the layer of logic that you ask above, but only 3 LTS. Physically, you need 3 alias joined the dimension of time with the join specifications you mention of course.

    PS: Jeff wrote about this a few years if you want to take a look.

  • Columns in the dimension fact table

    OBIEE, can we use a column of fact in the related dimension table where this column is only a description column? Well Yes, I know that use columns of fact indeed and volumetric size... But what exactly will question if we do? I have observed in one model... No data connection was there to test...

    Hi Hari,

    Why you cannot create two tables MDB is as a fact and DIM and place all the columns in the description of Sun and measures actually?

    in this way, you should reach patterns star in MDB

    http://www.varanasisaichand.com/2012/04/fact-and-dimension-from-single-source.html  (2nd method)

    Thank you

    Angelique

  • Where is the dimensions column in the finder?

    I wanted to be able to sort a folder full of images on my network by dimensions.

    I'm not able to find the column for the dimensions in the list view.

    Can someone help me find this?

    Thank you!

    Hi nomad2224

    Right-click (Ctrl-click) on the bar of the column and select a side to add a dimension column.

  • ADF 11g - adding serial No. sum of column/calculation of column in the table of the ADF.

    Hello

    -How can I add serial number of column in the table of the ADF.
    -What is the way to calculate the sum of a column at the end of the table. (Table of the ADF). That is to say.
    10
    20
    15
    ______
    45


    Niaz M

    Hello

    Here you have some links to blog posts how do the sum:
    http://apps.branislavnemec.com/blogs/faces/bjanko/blogs.jsp?blog=bjanko20070725180020
    http://Kuba.zilp.pl/?id=781

    Kind regards

    Branislav

    Published by: Branislav Nemec June 6, 2011 11:23

  • Is there an alternative way to compute the sum of a column without accessor view

    Hi Experts,

    JDev 12 c,

    I have a column A and I'm total calculation of column A with the same VO as a view accessor. And calculating as below

    EmployeeViewAccessor.sum ("ColumnA").

    But this way, it loads the VO 2 times as it loads the accessor aswell.

    So is there an alternative way to calculate the sum of a column.

    Thank you

    Roy

    Use the analytical function, please see below Ex

    http://docs.Oracle.com/CD/B19306_01/server.102/b14200/functions163.htm

  • Validation on the column to sum as a column <>100%

    Dear friends

    I have created table to use in query

    Select

    "ROWID",.

    "REQUEST_ID",.

    "CALL_FROM_DATE,"

    "CALL_TO_DATE,"

    "TOTEL_CALL,"

    "FILTER_PER,"

    "USER_CNT_SAMPEL_PER,"

    'NET_SAMPEL_COLLECT '.

    from 'EBA_SB_EXT_SURV_REQ_CR_02' where REQUEST_ID =: P325_REQUEST_ID

    I must apply the validation on USER_CNT_SAMPEL_PER column, I need if the sum of USER_CNT_SAMPEL_PER is not equal to 100, it must be the msg of error display "percentage of the sample of the user should be 100%.

    I used the Expression PLSQL

    SUM(:USER_CNT_SAMPEL_PER) = 100

    and the msg of error SUM OF USER_CNT_SAMPEL_PER NOT EQUAL to 100.

    But it does not work.

    How can I do this

    Thank you

    create before the process validation and Informatics

    declare

    l_tot number: = 0;

    Start

    because me in 1.apex_application.g_f05.count

    loop

    l_tot: = l_tot + nvl (to_number (apex_application.g_f05 (i)), 0);

    end loop;

    : P324_CNT: = l_tot;

    end;

    and create process\

    324_cnt = 100

    sum of the user sample shoulde be 100.

  • How to get the last row and the sum of all columns in a query

    Hello

    is there a way to get the last record for a column and the sum of all the Archives to another column in the same query.

    Best regards

    You must set your needs correctly volunteers to help here...

    Your data are not good enough to bring you a precise solution. Purpose, you do not have a column, which draws a distinction between the first and the last entry.

    The solution becomes easy based on your design.

    I introduced a grouping called 'id' column and a time column called 'time_of_insert' (only this way you can say with confidence that you can differentiate between the first and last (also a foolproof solution) - you can possibly use sequence (instead of date but if you say that you can insert two lines at the same time) ((and then likely sequence would be a better choice to differentiate instead of a timestamp field) etc...)

    With your sample data, something like this can be done to get the desired results.

    -----------------------------------------------------------------------------------------------------------------------

    WITH dataset AS

    (SELECT 1 id, 10 used, 8 remain, systimestamp + 1/24 time_of_insert FROM DUAL

    UNION ALL

    SELECT the 1 id, 1, 7, systimestamp + 2/24 FROM DUAL

    UNION ALL

    SELECT the id 1, 2, 5, systimestamp + 3/24 FROM DUAL

    UNION ALL

    SELECT 1 id, 1, 0, systimestamp + 4/24 FROM DUAL

    UNION ALL

    SELECT 1 id, 0, 0, systimestamp + 5/24 FROM DUAL

    UNION ALL

    SELECT the 1 id, 1, 4, systimestamp + 6/24 FROM DUAL)

    SELECT *.

    (SELECT SUM (used) ON sum_all)

    FIRST_VALUE (stay)

    COURSES (PARTITION BY id ORDER BY time_of_insert DESC)

    last_row

    Of THE dataset)

    WHERE ROWNUM = 1;

    Output:

    ------------------------

    SUM_ALL LAST_ROW

    ------------------------------

    15                  4

    See you soon,.

    Manik.

  • Columns of the sum of different record count of joined tables

    I have a problem with a query, please help.

    I have two tables:
    create table rec_a (key_code varchar(20),
                    TOT_AMT varchar(20),
                    INV_AMT varchar(20))
    / 
     
    create table rec_B (key_code varchar(20),
                    INVOICE_AMT varchar(20),
                   PAID_AMT varchar(20))
    / 
     
    insert into REC_A values (123123,  1168182.16, 1168182.16);
    
    insert into REC_B values (123123, 205699.04,205699.04);
    insert into REC_B values (123123,130912.78,130912.78);
    insert into REC_B values (123123, 81622.87,81622.87);
    insert into REC_B values (123123, 438032.43,438032.43);
    insert into REC_B values (123123, 159936.17,159936.17);
    insert into REC_B values (123123, 151978.87,151978.87);
     
    Table 1
    KEY_CODE TOT_AMT INV_AMT
    123123 1168182.16 1168182.16


    Table 2
    KEY_CODE INVOICE_AMT PAID_AMT
    123123 205699,04 205699.04
    123123 130912,78 130912.78
    123123 81622,87 81622.87
    123123 438032,43 438032.43
    123123 159936,17 159936.17
    123123 151978,87 151978.87


    I wrote a query to sum up all the areas (tot_amt, inv_amt, invoice_Amt, paid_amt)
    SELECT B.key_code,sum(A.invoice_amt),sum(a.paid_amt),SUM(b.tot_Amt),SUM(b.inv_amt) FROM rec_a B, rec_b A WHERE A.KEY_CODE=B.KEY_CODE AND B.KEY_CODE in ('123123')
    group by B.key_code
    I got this:

    KEY_CODE SUM (A.INVOICE_AMT) SUM (A.PAID_AMT) SUM (B.TOT_AMT) SUM (B.INV_AMT)
    123123 1168182.16 1168182.16 7009092.96 7009092.96

    But I expected this

    KEY_CODE SUM (A.INVOICE_AMT) SUM (A.PAID_AMT) SUM (B.TOT_AMT) SUM (B.INV_AMT)
    123123 1168182.16 1168182.16 1168182.16 1168182.16


    Can someone help me out here?

    Thank you

    Published by: 1003064 on April 29, 2013 03:19

    Hello

    1003064 wrote:
    I have a problem with a query, please help.

    I have two tables:
    Table 1
    KEY_CODE TOT_AMT INV_AMT
    123123 1168182.16 1168182.16

    Table 2
    KEY_CODE INVOICE_AMT PAID_AMT
    123123 205699,04 205699.04
    123123 130912,78 130912.78...
    123123 81622,87 81622.87
    123123 438032,43 438032.43
    123123 159936,17 159936.17
    123123 151978,87 151978.87

    I wrote a query to sum up all the areas (tot_amt, inv_amt, invoice_Amt, paid_amt)

    SELECT B.key_code, sum (a.invoice_amt), sum (a.paid_amt), SUM (b.tot_Amt), SUM (b.inv_amt) FROM rec_a A, rec_b B WHERE A.KEY_CODE = B.KEY_CODE AND B.KEY_CODE in ('123123')
    B.key_code group

    I got this:
    KEY_CODE SUM (A.INVOICE_AMT) SUM (A.PAID_AMT) SUM (B.TOT_AMT) SUM (B.INV_AMT)
    123123 1168182.16 1168182.16 7009092.96 7009092.96

    But I expected this

    KEY_CODE SUM (A.INVOICE_AMT) SUM (A.PAID_AMT) SUM (B.TOT_AMT) SUM (B.INV_AMT)
    123123 1168182.16 1168182.16 1168182.16 1168182.16

    Thus, the last 2 columns must be exactly what is stored in table1? Then either
    b include these columns in the GROUP BY clause and not to use the SUM,
    (b) the GROUP BY on rec_a alone, separately, can't join the results to the rec_b, or
    (c) using MIN or MAX, instead of SUM. (Anyone. Since there is only one value, MIN will be the same as MAX.)

    Here is an example of (a):

    SELECT    B.key_code
    ,       sum (a.invoice_amt)     AS sum_invlice_amt
    ,       sum (a.paid_amt),     AS sum_paid_amt
    ,       b.tot_Amt
    ,       b.inv_amt
    FROM        rec_a          A
    ,        rec_b          B
    WHERE        A.KEY_CODE     = B.KEY_CODE
    AND        B.KEY_CODE      in ('123123')
    group by  B.key_code
    ,            b,tot_amt
    ,       b.inv_amt
    ;
    

    I hope that answers your question.
    If not, post a small example of data (CREATE TABLE and only relevant columns, INSERT statements) for all of the tables involved and the results desired from these data.
    Point where the above query is to produce erroneous results, and explain, using specific examples, how you get the right results from data provided in these places.
    Always say what version of Oracle you are using (for example, 11.2.0.2.0).
    See the FAQ forum {message identifier: = 9360002}

  • Can be parallelized Alter the dimensions of the column to change tables

    Hi all

    Can be parallelized Alter tables to the dimensions of the column to change.

    I was able to set the explain plan of parallelized command CREATE INDEX and CREATE TABLE STATEMENTS and view the plan of the explain command.
    But when I try to apply the market in PARALLEL for an ALTER TABLE to change column size, explain the plan is a failure.

    Ex:
    EXPLAIN THE PLAN TO ALTER / * + PARALLEL (10) * / EMP_BLKP_1 TABLE MODIFY ENAME VARCHAR2 (40);
    ORA-00900: invalid SQL statement

    But when I run the alter even outside the plan to explain that it works very well. But I don't know if parallelism is applied for that change the order.

    Receive your answer.

    Thank you
    NKM

    http://docs.Oracle.com/CD/E11882_01/server.112/e26088/sql_elements006.htm#SQLRF50801

    >
    The PARALLEL indicator tells the optimizer to use the specified number of concurrent servers for parallel operation. The indication applies to SELECT it, INSERT, MERGE, update, and DELETE portions of a declaration, as well as for the table scan part. If no parallel restriction is violated, the flag is ignored.

  • Calculation of the sum of a column on a XML editor RTF with NULL values

    Hello

    I have a problem to get the sum of a column in XML editor RTF, if one of the lines has a null value.

    say, I have 4 columns and values

    CASES1:
    NULL, NULL, 4, NULL
    Sum, I expect is: 4

    CASE2:
    NULL, NULL, NULL, NULL
    I'm waiting for is a null

    Is there a way to do this?

    Thank you
    Anita

    Try this

    AMT's column

  • The data forms Web site - how to display the dimensions of all the columns?

    Hello

    I'm working on a data form. I took accounts in lines and period, year and scenario in my columns. The first pass is displayed correctly-> P #JAN. Y#@CUR. S #ACTUAL
    But when I used the second col-> P #FEB. Y#@CUR. S #ACTUAL and save my data form. I can see the year and only col1 scenario dimension. Col2: Only FEB appears without year and scenario. How can I spread the year and the other columns scenario, rather than display only in col1. Your help will be greatly appreciated. Thank you.

    If you use the standard Web in the workspace form tool, you can bring up the form in edit mode, select the Details tab and there is an option "Repeat the headers", Just check the box and you should be good to go.

    JOINT TASK FORCE

  • Hour/Min column in the Time Dimension

    Please can someone help me with the script to fill in the time Dimension Table that contains a column of hours/min. Here's my Time_D structure:

    Year
    Quarter
    Month
    Name of the month
    Week
    Day
    Hour
    Min

    Also is it a good practice to have the hour/Min column in the time Dimension?


    Thanks in advance.
    Concerning
    B

    B,
    Sorry if I confused things a bit...
    I wanted to say in the MDB layer, you can model a dimension table (time) with the path complete drill (year-> quarter-> month-> day-> hour-> Min)
    This a logical table would have two sources of logical table to map required fields of your two tables of phyiscal (Date_Dim and Time_Dim)
    You must define the levels of content accordingly for each logical table source, so the user in responses can perfectly break of the year all the way up to Min, their sound a single dimension, actually its two tables and the BI server switches according to the levels of content in the LTS.

    Sorted?
    Let us know if you get the probs.
    Alastair

  • calculate the sum of the two columns - display the result in the third column

    Hello

    I have a report and I want to calculate the sum of the two columns of the report and display the total in the third column.

    For example: Sample_My_Report

    Col1 Col2 (Col1 and Col2) Total

    3-7-10


    can someone help me with this question.

    Thank you.

    Hello:

    If your report is an IR you can use the menu "Tool" to add columns calculated at the State

    CITY

  • Calculate the sum of the 2 columns in the total column.

    Hello everyone.

    I have a question I hope you can help us

    I use the form of oracle 10 g , I made the table student FYI There are 5 columns ( HomeWorks, project, Midterm1, Midterm2,FinalExam), , I need to calculate these brands and put it in ( Total ) column using the form of the oracle. How to? .

    Another thing is it possible for me to restrict the user so that he can not enter more than 10 points for homework and not more than 15 points for project, etc.?

    I hope you can answer me I am really really really really grateful that I searched online, but no real solution especially for the second part of the question. will I change the varchar2 to the numbers?

    Thank you

    Yes... What you have to do is, you create when validating the element trigger on assignment, then put under code of the project

    IF (: blockname.itemname) > 20 THEN

    MESSAGE ("you must enter only less than 20 brands '");

    RAISE FORM_TRIGGER_FAILURE;

    END IF;

    Make the total, rank as a display element. Create a button contained within this block and put the code below in this WHEN the BUTTOM PRESSED trigger

    DECLARE

    v_total NUMBER;

    BEGIN

    v_total: =: Blockname. Mid1 +: Blockname. MID2 +: blockname.assignment +: Blockname. Final +: Blockname. Project;

    : blockname.total: = v_total;

    : blockname.grade: = CASE WHEN v_total<60   then ="">

    WHEN v_total<65   then ="">

    WHEN v_total<70   then ="">

    WHEN v_total<75   then ="">

    WHEN v_total<80   then ="">

    WHEN v_total<85   then ="">

    WHEN v_total<90   then ="">

    WHEN v_total<95   then ="">

    WHEN v_total<=100 then="">

    END;

    END;

Maybe you are looking for

  • How to restore an image removed from Photos to iCloud

    By mistake I deleted a picture of pictures. How to restore the photo to iCloud?

  • iTunesMiniPlayer.dll cannot save. HRESULT-2147023782.

    With the installation of iTunes, I get the following message C:\Pogram Files\iTunesMiniPlayer.dll module cannot be saved. HRESULT-2147023782. This happens when I reinstall and install recently after I deleted all software apple with Windows 10 When I

  • Audio drivers for compaq presario SR1420AN

    I had to reinstall windows on a friends computer, a compaq presario SR1420AN and long story short, that everything was going well until I came to install the audio drivers. I have tried everything I can think of to get the sound working... I tried th

  • How to manage settings of fps?

    Hi there everyone, I use iMovie on a Macbook Late 2008 for a bit, but I recently started to edit my GoPro on a new Macbook 2011 clips. Moment, until now 60 fps image editing was really simple for me: I would slow down the clip to 50% to get a slow mo

  • Pop - ups study of HP product improvement will not stop even after uninstalling it.

    I opted in to the Technical Support function when I was installing my HP 8600 Pro thinking it would be only a one time deal but I was wrong.  At least twice a week the notification appears that collected information is ready to be passed and becomes