Subtotal by attribute

Hi Gurus,
Here'a a begginer question related to subtotals:
I cannot make a subtotal based on an attribute wich is not 1:1 with the dimension key.
What do you suggest to do next ?
Thanks,
Markus

Suman,
Even I succeded to display the attribute in the first row, the subtotal follows the partner_key logic (you mentioned this in a post earlier)  - I mean it groups according to the values found in partner_key , not like attribute fiscal_code.
By disabiling I meant I've suppresed the key and text display.
Next step is to provide two columns containig partner ID and partner description  wich was already provided as an attribute in the first column ..
Thanks for your fast response and sorry not providing all the picture   ,
M

Similar Messages

  • Calculate Column Subtotal in  Attribute View

    Hi,
    Is it possible to calculate the Column subtotal in Caluclation View itself likethe way we do in ALV.
    I want to do this calculation in the Calculation View itself.
    I thought of doing that through  Calculated Column but the SQL Function SUM() doesn't work there.
    Below is how my Calculation View looks like:
    I want the output to be like this (Highlighted in Green):
    I am getting the field Allocation from my Attrbute View ZAT_VBRK_VBRP(Join of table VBRK and VBRP) and ZVBAK is just an attribute view for VBRK.
    Thanks,
    Gaurav

    Hi Shankar,
    Sub_totals can be achieved through the SQL query using the Grouping_sets which is something like this,
    select col_1, col_2, col_3, sum(col_4)
    from <Table_name>
    group by grouping sets LIMIT 2 WITH SUBTOTAL
    ((col_1, col_2),(col_3));
    Usually this can be done in the front end reporting tool but,If you want to continue with the calculation_view where you want the sub total to be appended as a "New Tuple" then you will have to go with the CE_Functions using the sql_query.
    This is something new that i can learn today, lets see how the experts will guide us with the approach.
    Regards,
    Krishna.

  • Subtotal by attributes

    Hi all,
    I want to know if there's any way to sum values in rows of a layout when changing attribute value in row.
    E.g.
    Costcenter has class1, class2, class3 as attribute.
    There are many cost center with the same class1. I want to totalize planned values for class of cost center.
    Char val   class1       class2     class3            keyfig
    cc1.0.0      1            0           0               100
    cc1.1.0      1            1           0               150
    cc1.1.1      1            1           1               300
    (total cc1)                                           550
    cc2.0.0        2            0           0               100
    cc2.1.0        2            1           0               100
    (total cc2)                                          200 
    There are 2 possible solution:
    1 create total caracteristic values and sum values using "atrv" costruct of a fox formula.
    2 sum values using javascript..
    Any other suggestions?
    (I don't have to use hierarchies)
    Thanks in advance.
    Vincenzo

    hi carlone,
       when you change the attributes, i guess javascript solution is best.
      look at this links ,
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/e55cd590-0201-0010-d287-ea11153c3cfd
    http://help.sap.com/saphelp_nw04/helpdata/en/55/610e2db57911d4b62c006094192fe3/frameset.htm
    Thanks & Regards
      Varun Kumar CN

  • Navigational Attribute in BEx

    Hi,
    I have a problem with  navigational attribute in BEx reporting.  Product hierarchy 1 to 4 (0PRODH1 to 0PRODH4  referencing 0PROD_HIER) is a navigational attribute in 0MATERIAL. In query from an ODS I am able to include them and able to filter on it using a variables, but I am not able to get subtotal on the basis of PRODH3, but able to subtotal on the basis of PRODH1 & PRODH2.
    I run RSRV on 0MATERIAL & 0PROD_HIER and there is no error on it.
    If anybody know how to rectify this issue pls reply.
    Thanks
    EV

    Try this:
    My experience is that the property of showing subtotals in bex, is pointing at the characteristic to the left in your report  of the one you are changinin  .
    If you have
    Fiscal year, profit Center , Customer ,  Product,
    And want subtotals on the two first. BUT NOT Customer and product..
    The property show subtotals should be choosen for the first three.
    Fiscal year, profitcenter AND customer.
    Hope this helps.

  • Implementing Subtotal functionality

    Hi,
    I have a web dynpro application in which i need to implement the subtotal functionality for a table.I have a table which has 5 columns, where in the first 2 columns have datatype string.So i need to find the sub total of the third column wrt first column and second column.In the same way, i need to find the subtotal of any column with integer datatype wrt any column with string datatype.
    Please suggest me how to proceed.
    Regards,
    Padmalatha.K
    Points will be rewarded.

    Hi,
    Create a calculatted attribute to do the calculation
    public int getSub_Col(IPrivateTestCompView.IContextElement element)
        //@@begin getSub_Col
           int x = element.getAttributeValue("<Your first attribute");
           int y = Integer.parseInt(element.getAttributeValue("<Your second string attribute"))
          return x+y;
        //@@end
    Pl handle the exceptions
    Regards
    Ayyapparaj

  • Calculating subtotal in table control

    Hi all my requrement is like this
    I am using one tabbed screen .
    in the last tabbed screen i have used table control in that
    screen there is one requirement so that to  calculate the subtotal as we can do in case of alv reporting by using the subtotal button .
    can anybody help me how to do this .

    HI,
    subtotal_text
    Use
    Output text for subtotals in the grid control if the subtotal criterion (column used by the user for calculating the subtotal) is hidden. In the default setting, the ALV Grid Control outputs the column header of the subtotal criterion and the value to which the subtotal calculated refers.
    Event parameters
    Meaning
    ES_SUBTOTTXT_INFO
    Type LVC_S_STXT
    Structure with information on the subtotal criterion
    EP_SUBTOT_LINE
    Type Ref To DATA
    Reference variable to the inserted subtotal line in the grid control. Columns for which no total was calculated remain set to their initial value.
    E_EVENT_DATA
    Type Ref To CL_ALV_EVENT_DATA
    Attribute M_DATA of this object is a reference to the subtotal text.
    For an overview, see: Events of Class CL_GUI_ALV_GRID
    Example
    You display a table with data of structure SFLIGHT in an ALV Grid Control. We now change the pre-set subtotal text for subtotal criterion plane type of table SFLIGHT :
    Define and implement an event handler method for event subtotal_text . Register this event with SET HANDLER .
    Call a subroutine within this method and pass the event parameters to that subroutine.
    Event parameters ep_subtot_line and e_event_data contain reference variables to generic data type DATA . This is why you must use field symbols in the subroutine:
    FORM method_subtotal_text USING es_subtottxt_info TYPE lvc_s_stxt
                                   ep_subtot_line TYPE REF TO data
                                   e_event_data TYPE REF TO
                                   cl_alv_event_data.
      DATA ls_sflight LIKE sflight.
      FIELD-SYMBOLS: <fs1> STRUCTURE sflight DEFAULT ls_sflight,
                    <fs2>.
      IF es_subtottxt_info-criteria = 'PLANETYPE'.
        ASSIGN ep_subtot_line->* TO <fs1>.
        ASSIGN e_event_data->m_data->* TO <fs2>.
        CONCATENATE es_subtottxt_info-keyword ': '
                    <fs1>-planetype INTO <fs2>.
      ENDIF.
    ENDFORM. " METHOD_SUBTOTAL_TEXT
    Result
    Check your result as follows:
    Calculate the total for a column.
    Calculate subtotals for column plane type .
    Hide column plane type . To do this, use either the standard context menu or a new layout.
    The new text defined is displayed at the beginning of a subtotal line.

  • ALV SUBTOTAL (Change at summation Level)

    Hi All,
    I need to add some code at the subtotal level of the ALV report output. My output shound look something like this.
         FLD1     FLD2     FLD3     FLD4
         A1     B1     1     AA
         A1     B1     2     BB
    <i><b>Sum     A1     B1     3     C</b></i>
         A1     B2     11     D1
         A1     B2     22     D2
    <i><b>Sum     A1     B2     33     CD</b></i>
         B1     B1     1     D1
    <i><b>Sum     B1     B1     1     CCD</b></i>
         B1     B2     5     D1     
    <i><b>Sum     B1     B2     5     CCDD</b></i>
    I should be able insert a summation level into the output so that the FLD4 can be changed based on the total of FLD3 at the summation level.
    Please let me know if this is a possibility atleast.
    Thanks in advance..!
    Jr.
    Message was edited by: Jr Abaper

    You need to build a sort table with feild you want to have for subtoal by setting one of attributes subtot    = 'X'.
    Data:
          dt_sortcat TYPE slis_t_sortinfo_alv,    "table - sort table
           ds_sortcat LIKE LINE OF dt_sortcat,     "structure-sort structure
      ds_sortcat-spos      = '1'.
      ds_sortcat-fieldname = 'VBELN'.
      ds_sortcat-tabname   = 'IT_DATA'.
      ds_sortcat-up        = 'X'.
      ds_sortcat-down      = space.
      ds_sortcat-subtot    = 'X'.
      APPEND ds_sortcat TO dt_sortcat.
       ds_sortcat-spos      = '2'.
      ds_sortcat-fieldname = 'POSNR'.
      ds_sortcat-tabname   = 'IT_DATA'.
      ds_sortcat-up        = 'X'.
      ds_sortcat-down      = space.
      APPEND ds_sortcat TO dt_sortcat.
    and pass the sort table to the exporting parameter IT_SORT of the REUSE_ALV_GRID_DISPLAY function module.
    For Demo programs: Go to se38 and enter BCALV* and press F4 key you will get list of ALV demo programs
    Message was edited by: Sid

  • Conditionally hide subtotal row

    I am creating a new analysis where I want to conditionally hide a subtotal row in a pivot table view. I have two columns - Is Consolidated and Property Name. Properties can be consolidated or not so I have Is Consolidated as an attribute (values True or False) and I add both to an pivot table view of an analysis. I made Is Consolidated so that it has subtotals after and then hide the Is Consolidated column so that the pivot table view looks like so:
    Property A
    Property B
    Property C
    True Total
    Property D
    Property E
    False Total
    Grand Total
    However, I want the report to look like so (don't show the False Total line):
    Property A
    Property B
    Property C
    True Total
    Property D
    Property E
    Grand Total
    I found the following - http://gerardnico.com/wiki/dat/obiee/answer_xml but my situation is a little different and when I pull the equation out it never finds it so it doesn't ever apply the conditional formatting.
    Is this possible?

    950121 wrote:
    I don't understand what you're proposing. With this implementation I get the error "Numbers of columns and their data types must be consistent across all criteria and Result Columns".Most detailed steps I could write :)
    1) Login in OBIEE analytics.
    2) Create a new analysis/answers using the subject area that the report should be built out of.
    3) In the criteria tab for the Report 1, drag the following columns: Property Column, and Fact Metric.
    4) For the fact metric column, click on FX and write the following formulae: FILTER(Metric using Flag = 'TRUE')
    5) Create all the filters as you need for this based on the prompts provided on the dashboard page
    Time to create second report to display the subtotal:
    6) Click on combine with similar request and select the same subject area and this will create second line of reports below the result columns.
    7) The concept here is, you can do an union of reports as long as all the reports have same set of columns and matching datatype's.
    8) Now select any column from subject area that is of type character, and obviously the second column which is the metric.
    9) Click on Fx on the first column and change it to 'Total' to hardcode it. Change the fx of the second column to FILTER(METRIC USING FLAG = 'TRUE')
    Time to create third report:
    10) Click on edit, and click on Add new criteria to add third line of report in the result columns set.
    11) Now repeat the steps in the first report, and change the metric to filter by 'FALSE' instead of true.
    12) Apply the same set of prompts across 2 and 3 reports also.
    Apply the formatting on the result columns per your requirement.
    Thanks.

  • Financial Reports and Attribute Dims

    Hi,
    Is it possible to include Attributes in a Financial Report and subtotal by the particular Attribute by employee? For Example:
    Column Definition has Account = Insurance Cost with a scenario version etc.....
    Jan Feb Mar Qtr1
    Smith, John Cigna PPO 10 10 10 30
    Jones, Justin Cigna PPO 12 12 12 36
    SubTotal - Cigna PPO 22 22 22 66
    Long, Brad Kaiser 30 30 30 90
    Harvey, Bill Kaiser 24 24 24 24
    SubTotal - Kaiser 54 54 54 54
    Grand Total 76 76 76 120
    Where Column 2 'Type' is an attribute assigned to the Employee in Column 1. Also what if column 2 was a 'SmartList' in Accounts dimension instead? Right now outline is a Smart List however getting it to Subtotal is impossible I think as the SmartList is an Account named 'Plan Type' thus it has t be in columns as the report has Account = Insurance Cost in the column definition too.....

    Hi
    In answer to your first question yes it is possibe to report a dimension by its associated attribute. You will need to drag the attribute dimension and the employee dimension onto the rows for the grid. You may want to play around with whether the attribute dimension comes before or after the employee dimension to see whether there is a noticeable performance difference.
    If I am reading your post correctly you currently want to have:
    Column1 - Employee
    Column2 - Attribute / SmartList
    Column3 - Account (Insurance) > Jan
    Column4 - Account (Insurance) > Feb
    Column5 - Account (Insurance) > Mar
    Column6 - Account (Insurance) > Q1
    This will work fine for an attribute but if you want Column 2 to be a smartlist then you would have to put your account dimension into columns and that would mean that your smartlist would have to appear in only 1 period, i.e. if it changes from Jan to Feb then you would need more than one column to report it. It will also be harder to get a subtotal using a smartlist, with an attribute the subtotal will naturally be available by selecting the top member of the Employee dimension with your attribute (it will dynamically sum all members with the attribute you are calling).
    Hope this helps
    Stuart

  • Attribute text_fieldname of alv field catalog

    Hi all,
    There is a attribute called text_fieldname in alv fieldcatalog(slis_fieldcat_alv) . Has anyone used it ? Or does anyone know its purpose?
    Regards,
    Kavitha

    Hai Kavitha,
    TEXT_FIELDNAME : Field name of internal table field. You can use this field to define a reference to a field that is used as the description for the current field. If a subtotal is calculated for the current field, the ALV Grid Control displays the descriptions in the field assigned.
    Example: Your output table contains one column for material numbers and one column for the description of what these numbers mean (such as clockwork). If you calculate subtotals for the material numbers, only these numbers are usually displayed as the subtotals text. Based on the link to TXT_FIELD , you can refer to the corresponding column with the material description. This description is then used as the subtotals text.

  • ASO Cube with attributes very slow in retrieval

    Hi,
    I have a ASO Cube with 5 base dimensions and 8-9 attributes on the entity dimension. I have only 5-6 measures, which do the averages and counts based on the 40 day period. Howere, the data is loaded at the 15 minute increment
    Entity
    Date - (date-time, lowest level being date)
    TIme - ( 15 minute time for the full 24 hour period, has a attribute assocuated with oit)
    LocationType
    Measures.
    The sample formula is
    IIF(Islevel([Locations].CurrentMember,0), Avg(CrossJoin({[Measure].[Sale]},{[DateDim].CurrentMember.lag(40):[DateDim].CurrentMember})),Missing)
    Is there a way, i can have this calculated as a part of the script? DO you suggest i create a BSO, to do these calculations and pass on the result.
    In OBIEE, the report is to display the followung based on the date input.
    Entity Gen7, Entity Gen 6..... Entity Gen 2, Attr1, Attr2, Attr3, Attr4, Attr5, Attr6, Attr7, Measures

    2 things I would look at
    1st - I don't know how much performance you would get out of this, but I'm not clear why you are using a crossjoin in your MDX, it seems unnecessary and may cause more overhead. The following should work, you could also try using IsLeaf instead and see if that is any faster
    IIF(Isleaf([Locations].CurrentMember),
    Avg({[DateDim].CurrentMember.lag(40):[DateDim].CurrentMember},
    [Measure].[Sale], INCLUDEEMPTY)
    2nd - your problem mostly revolves around the fact that you are running a 40 member sum/avg for every member you are querying. It also sounds like the average is at the Day level, which is not level 0. So for all forty days, ASO also has to calc the results of each of those days. Remember that aggregations only get you so far, you should really think of everything in ASO as dynamic and that is why you can see what you have set up is not going to work that well, it is too calc intensive.
    I don't know how practical this is, but to get this to work fast you would probably need to break out the 15 minute increments below the day level to another dimension so the day level becomes a stored level zero member. The 15 minute increment dimension should also be stored. If at all possible you would want to have an alternate stored hierarchy with the 40 days you want to base the average on. Enable alternate hierarchies in your aggregations, then change your MDX calc to be based on the parent of the 40 day hierarchy divided by 40. That would be fast.
    I suppose you could opt to not break out the 15 minute increments and just have the shared hierarchy made up of the 15 minute increments that are below the 40 days. That would still give you a good stored subtotal that with some query hints you could get optimized.

  • Epm11 attribute dimensions sum

    In outline, there are 13 dimensions:
    -YearTotal (Time Dimension)- Dense
    -Accounts - Dense
    -Scenario - Dense
    -Costing -Dense
    -Cumulative- Dense
    -Currency -Sparse
    -Company -Sparse
    -Doctype -Sparse
    -Years -Sparse
    -Sales Dep -Sparse
    -Geographics -Sparse
    -Customer -Sparse
    -Product -Sparse,
    and 6 attribute dimensions:
    -Standart
    -Anme
    -Hardness
    -Coat Type
    -Product Type
    -Logistics.
    Scenario dimension children : Actual and PYear (Previous Year value : Formula =@SHIFT ("Actual",-1,@LEVMBRS("Years",0)); ).
    For a material that was sold in 2009 and not sold in 2010:
    -if we dont use the Product Type attribute dimension, 2010->Pyear value is coming.
    Material Year Scenario Subtotal
    A 2010 Actual missing
    A 2010 Pyear 15000
    A 2009 Actual 15000
    -if we use the Product Type attribute dimension, 2010->Pyear is missing but it is not true.
    Material        Product Type_ Year Scenario Subtotal_
    A PT 2010 Actual missing
    A PT 2010 Pyear missing
    A PT 2009 Actual 15000
    I guess the reason is that there is no block for this material and year combination (A->2010) . What can I do ,can you give a suggesstion ?
    Thanks a lot.

    Yes they can.Basically, attributes are linked through to your base dimension anyway.You can either @withattr or @attribute in your filter.eg.WRITE/READ @attribute("bottle")where "bottle" is a member of your "pkg type" dimension say

  • Can I simulate subtotal by Calc script?

    Since there is no subtotal in Essbase, I wonder can subtotal be simulated by Calc Scrip if use BSO.
    As far as I know, there are may other BI solutions which could provide subtotal.
    It is very unfortunate that Essbase does not provide subtotal.

    First understand essbase is a server technology, it should be designed in suchway that will support the common calculation and reporting requirements.
    Before implementing essbase you need to identify the common query patterns and incorporate the functionality required to support that.
    you are asking about the subtotals, if the members defined for the subtotals are the groupings defined by a specific functinality or attributes.
    You can define a attribute dimensions and can assign the attributes to these base members.
    Then if you query the cube by the attributes by default you will get the sum of all base members(Subtotal which you are expecting).
    If it is not the case and you are not in a position to predefine any thing and you want subtotals based on the result sets of dynmic querys.
    Then It is better to try it out in the HFR like client side.
    In the HFR you can insert a Formula row and can calculate the total based on the results.

  • Get Attribute values from a page and procedure exception handling?

    Hi All,
    I have created new page with two input attributes not based on any VO. This page is created to capture two values and pass these to an AM method upon pressing OK button. The method in AM will call a procedure with two in parameter expecting the two values captured from the above said page.
    I have two questions, first one how to capture the values entered by the page in the controller class and advises me how to handle exceptions when my procedure fails.
    I can not use something like this since this page is not based on a VO
    String fromName = (String)vo.getCurrentRow().getAttribute("FromName");
    Do I have to create a dummy VO like select '' name1, '' name2 from dual?
    Thanks for the help.

    Hi,
    Actually you can capture the parameters on the page like this way
    String test = (String)pageContext.getParameter("id of the text input bean");
    Now in procedure you can take an out parameter which stores the error messages on exception
    and return that out parameter in java.
    and then you can throw exception on page using OAException class.
    Thanks
    Gaurav Sharma

  • Encrypted="true" does not encrypt MBean attribute

    Hi,
    I have developed a Custom Weblogic Security Service Provider. I have also created
    an MBean
    to manage my provider. One of my MBean attributes is as follows:
    <MBeanAttribute
    Name = "JdbcPassword"
    DisplayMessage = "The JDBC Password to the security database"
    Type = "java.lang.String"
    Writeable = "true"
    Encrypted = "true"
    Default = ""password""
    />
    I have specified Encryped="true" above, however, the value I put in the Weblogic
    Console
    is still seen in cleartext in the config.xml. Why isnt it being encrypted? Or
    do I misunderstand
    the purpose of the Encrypted attribute?
    Thanks,
    Proneel.

    "Proneel Guptan" <[email protected]> wrote:
    >
    Hi,
    I have developed a Custom Weblogic Security Service Provider. I have
    also created
    an MBean
    to manage my provider. One of my MBean attributes is as follows:
    <MBeanAttribute
    Name = "JdbcPassword"
    DisplayMessage = "The JDBC Password to the security database"
    Type = "java.lang.String"
    Writeable = "true"
    Encrypted = "true"
    Default = ""password""
    />
    I have specified Encryped="true" above, however, the value I put in the
    Weblogic
    Console
    is still seen in cleartext in the config.xml. Why isnt it being encrypted?
    Or
    do I misunderstand
    the purpose of the Encrypted attribute?
    Thanks,
    Proneel.Hi Proneel,
    Could you please tell me what version of Weblogic are you using?
    Thanks,
    Carmen

Maybe you are looking for