Subtracting Columns (2columns in one measure)

Hi pros,
I am new to OBIEE and still exploring the functionalities. However; I find it difficult in making a way to subtract the values from two columns. For example,I will subtract the values under the column1(year 2009) and column2(year2010) and put the each of the result in the third column. I tried using $1-$2 but later found out that the values of $1 and $2 are different with the values of each columns.
Also is there a way that it would be dynamic based on the dashboard prompts? Because I will not only use 2009 and 2010 as years.
Also what is the meaning of "$"?
Thanks!

Thanks for replying RAM_CH. I forgot to tell, that the 2 columns I am talking about is under one measure only. This measure is called Period Estimates and has several columns under it "2008, 2009, 2010, etc." And I have only limited the results into 2008 and 2009. Do you know how to get the variables under this measure so that it would be dynamic.
By the way it is something like this:
When 2009 is chosen
Period Estimates
2008 2009 09/08Change
$1 $2 $3
Year ago shows up(2008) and the third column should automatically compute for the value of (2009-2008).
I tried $1-$2 but it showed wrong values.
Thanks.
Edited by: 862255 on Jun 1, 2011 6:58 PM

Similar Messages

  • How to put the proper header at each column in write to measurement file (.lvm) ?

    Hi,
           i would like to know one thing about the write to measurement file. Can i put the proper header at each column in write to measurement file (.lvm) ? and how can i do for it ? Could you show me a way to make it ?
    i am looking forward your kindly reply.
    thank you so much ..
    best regard,
    roxy

    Hi Mike,
                  Thank you very much for your help. It works .
    By the way, i would like to ask you about setting time interval. In the pic, X_Value column is for time column
    i would like to ask that when i use the write to measurement file, there got the x column that show time inside the excel file. In this column, i would like to set the time interval at every 210ms .The data may come in every msec but i just want to record the data at every 210ms .  for example, 210ms-420ms-630ms ..etc. how can i set it ?
    One more thing .. can i do it in graph as well ?
    i am looking forward your kindly reply.
    Thank you for your time.
    Best Regard,
    Roxy

  • Show Column Data In One Row

    Hello,
    Tell Me how i can show a single column data in one row.
    10
    20
    30
    To
    10,20,30

    If you are OK with displaying comma separated list or column data you could:
    SQL> select  ltrim(sys_connect_by_path(ename,','),',') ename_list
      2    from  (
      3           select  ename,
      4                   row_number() over(order by 1) rn,
      5                   count(*) over() cnt
      6             from  emp
      7          )
      8    where rn = cnt
      9    start with rn = 1
    10    connect by rn = prior rn + 1
    11  /
    ENAME_LIST
    SMITH,ALLEN,WARD,JONES,MARTIN,BLAKE,MILLER,SCOTT,KING,TURNER,ADAMS,JAMES,FORD,CLARK
    SQL> To display as separate columns you would need to either know number of rows:
    SQL> select  min(case rn when 1 then ename else null end) ename1,
      2          min(case rn when 2 then ename else null end) ename2,
      3          min(case rn when 3 then ename else null end) ename3,
      4          min(case rn when 4 then ename else null end) ename4,
      5          min(case rn when 5 then ename else null end) ename5,
      6          min(case rn when 6 then ename else null end) ename6,
      7          min(case rn when 7 then ename else null end) ename7,
      8          min(case rn when 8 then ename else null end) ename8,
      9          min(case rn when 9 then ename else null end) ename9,
    10          min(case rn when 10 then ename else null end) ename10,
    11          min(case rn when 11 then ename else null end) ename11,
    12          min(case rn when 12 then ename else null end) ename12
    13    from  (
    14           select  ename,
    15                   rownum rn
    16             from  emp
    17          )
    18  /
    ENAME1  ENAME2  ENAME3  ENAME4  ENAME5  ENAME6  ENAME7  ENAME8  ENAME9  ENAME10  ENAME11  ENAME12
    SMITH   ALLEN   WARD    JONES   MARTIN  BLAKE   CLARK   SCOTT   KING    TURNER   ADAMS    JAMES
    SQL> or use dynamic SQL.
    SY.

  • Multi-column Index vs One index for each column

    Hello everyone,
    i have one table about 20 000 000 rows, some developers have to generate reports on it and i want to create indexes on this table.
    The table has 34 columns, no primary key, no unique keys.
    The "where..." clause of the reports usually use 8 columns but some reports uses 8 + some other columns.
    can any one help me on what kind of indexes do i have to create?
    1. one index for each column used in "where clause"
    2. one index for 8 columns and some other indexes for other used columns
    3. one index for all columns
    or something else etc...
    br flag

    i have one table about 20 000 000 rows, some developers have to generate reports on it and i want to create indexes on this table.
    The table has 34 columns, no primary key, no unique keys.
    The "where..." clause of the reports usually use 8 columns but some reports uses 8 + some other columns.
    can any one help me on what kind of indexes do i have to create?
    1. one index for each column used in "where clause"
    2. one index for 8 columns and some other indexes for other used columns
    3. one index for all columns
    or something else etc...What's the version of your data base? what kind of database you have, DWH or OTLP? The answer might depend on the type of database as far as bitmap indexes might suit or might not depending if you are runing DWH or OLTP kind of database
    Let me suppose that you are runing OLTP database and you have a where clause with 8 columns.
    1) are all those where clause equalities (where col1 = and col2 =) or there are inequalities?
    2) could you evaluate the most repetitive columns?
    3) could you know the column that could have the best clustering factor (the column which most follow a certain order in the table)
    Based on that I would suggest to create one b-tree index having 8 columns (even though that it seems for me to high) this index should follow the following points:
    1) put the most repetitive column at the leading edge (and compress the index if necessary)
    2) put the columns that are used in equalitity predicate first
    3) put the column having the best clustering factor first
    The most precise index you have the best access you could gain.
    Of course that you have to know that an index access is not always good and a FULL table scan is not always bad.
    Best regards
    Mohamed Houri
    www.hourim.wordpress.com

  • How can i hightlight in excel 3 numbers in a column then skip one, and highlight the next?

    how can i hightlight in excel 3 numbers in a column then skip one, and highlight the next?
    Example: Column A
    highlight      3
    highlight      4
    highlight      5
    skip            6
    highlight      7

    hold down the cmd (⌘) key while selecting them.

  • How to have all columns display in one go in RSA3

    i'm trying to extract the sales order item (2LIS_11_VAITM) thru RSA3 into flat file.
    However, the maximum number of columns is limited to 90 columns ( with a hundreds of hidden fields by default). I don't see the system provide you the user parameter where you can change the output list to ALV grid rather.  Please advise how can I have all the columns displayed in one go ( even if the column header too shorten is fines to me)?

    mask as unanswer

  • The key columns of the country measure group attribute do not match in either number or data types to the key columns of the source attribute

    I have a country dimension which is used in 5 cubes. Now I want to change 'key column' property of the country attribute. Whenever I do this, I get an error as "The key columns of the country measure group attribute do not match in either number or
    data types to the key columns of the source attribute". I dont understand what this error is about.
    Can someone please help? Thanks in advance.
    -Regards,
    Raj Patil

    sounds like you need to verify your dimensional usage tab to verify the relationships between dim and fact on the measure group. 
    Hi Talktorajpatil,
    As Jon said, you can verify the relationships between dim and fact on the measure group on the dimensional usage tab. Use this section to define how you "join" your measure groups to your dimensions.  There may be a Dimension-Measure Group relationship
    that is defined using the wrong attributes and you'll need to select the correct attributes to link the Dimensions to the measure groups. Here are some similar thread for your reference.
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/74203b66-8a71-4681-8e47-8f99cce87b3d/error-on-the-measure-group-which-do-not-match-the-data-type-of-the-key-column?forum=sqlanalysisservices
    http://social.msdn.microsoft.com/Forums/sqlserver/en-US/2421058d-fd4a-44b8-8c7c-b0b349bbef2d/measure-group-attribute-key-column-does-not-match-source-attribute?forum=sqlanalysisservices
    Hope this helps.
    Regards,
    Charlie Liao
    TechNet Community Support

  • How do I make the particular column to editable one in the multicolumn list box?

    Hi,
    I am updating different parameters in the multicolumn list box.I am having four columns.
    I want to make 3 columns non editable to user and 4th column is editable one.
    How do i do this?
    Help me
    Regards
    Meenatchi

    Meenatchi wrote:
    I want to make 3 columns non editable to user and 4th column is editable one.
    Your question title & the message you ve posted are contradictory to each other.
    Normally a Multicolumn Listbox is a non-editable one, in that while you run you wont get the labeling tool to type some text.
    I think you can instead use a Table to achieve your purpose. Also see the below link.
    http://forums.ni.com/ni/board/message?board.id=170&message.id=131631#M131631
    Or, the attached VI, modified from that post, of course.
    - Partha
    LabVIEW - Wires that catch bugs!
    Attachments:
    Make some columns of a Table only as Editable.vi ‏32 KB

  • Subtracting Columns from Import File Using Import Script

    The file I am importing to FDM contains two amount columns, 1 Debit, 1 Credit. I want to have the Amount field populate as the Debit minus Credits. I have attempted an import script that is giving me an error in the bolded line:
    Function GBS_Amount(strField, strRecord)
    'Oracle Hyperion FDM Integration Import Script:
    'Created By:     
    'Date Created:     
    'Purpose:
    'Set variables
    dim strNatural
    dim strCurmnthDR
    dim strCurmnthCR
    dim strCurAmount
    'Store the Natural Account as Column 1 of 11 of a comma delimited file
    strNatural = Trim(DW.Utilities.fParseString(strRecord, 11, 1, ","))
    'Store the Current Month Debit Amount as Column 7 of 11 of a comma delimited file
    strCurmnthDR = Trim(DW.Utilities.fParseString(strRecord, 11, 7, ","))
    'Store the Current Month Credit Amount as Column 8 of 11 of a comma delimited file
    strCurmnthCR = Trim(DW.Utilities.fParseString(strRecord, 11, 8, ","))
    'Calculate the YTD Amount
    strCurAmount = strCurmnthDR - strCurmnthCR
    GBS_Amount = strCurAmount
    End If
    End Function
    What syntax do I need to use to subtract two defined variables?

    Hi Experts,
    I have a similar situation,I am trying to import the Multiple amount columns to be addedd and imported as one amount column.Below is the script I am using for the same,script is getting verified in Script editor but When I am trying to Load the File in import, I am gettig an error as below.but if I try to import without using the script for the amount, inport is getting done.I have attached script to amount column only.
    ERROR
    Code............................................. 9
    Description...................................... Subscript out of range
    Procedure........................................ clsImpProcessMgr.fLoadAndProcessFile
    Component........................................ upsWObjectsDM
    Version.......................................... 1112
    Thread........................................... 8380
    Scirpt being used
    Function Import_YTD(strField, strRecord)
    'Set variables
    dim strCurmnth1
    dim strCurmnth2
    dim strCurmnth3
    dim strCurmnth4
    dim strCurmnth5
    dim strCurmnth6
    dim strCurmnth7
    dim strCurmnth8
    dim strCurmnth9
    dim strCurmnth10
    dim strCurmnth11
    dim strCurmnth12
    dim strCurAmount
    strCurmnth1 = Trim(DW.Utilities.fParseString(strRecord, 20, 9, ","))
    strCurmnth2 = Trim(DW.Utilities.fParseString(strRecord, 20, 10, ","))
    strCurmnth3 = Trim(DW.Utilities.fParseString(strRecord, 20, 11, ","))
    strCurmnth4 = Trim(DW.Utilities.fParseString(strRecord, 20, 12, ","))
    strCurmnth5 = Trim(DW.Utilities.fParseString(strRecord, 20, 13, ","))
    strCurmnth6 = Trim(DW.Utilities.fParseString(strRecord, 20, 14, ","))
    strCurmnth7 = Trim(DW.Utilities.fParseString(strRecord, 20, 15, ","))
    strCurmnth8 = Trim(DW.Utilities.fParseString(strRecord, 20, 16, ","))
    strCurmnth9 = Trim(DW.Utilities.fParseString(strRecord, 20, 17, ","))
    strCurmnth10 = Trim(DW.Utilities.fParseString(strRecord, 20, 18, ","))
    strCurmnth11 = Trim(DW.Utilities.fParseString(strRecord, 20, 19, ","))
    strCurmnth12 = Trim(DW.Utilities.fParseString(strRecord, 20, 20, ","))
    If strCurmnth1="" Then strCurmnth1="0" End If
    If strCurmnth2="" Then strCurmnth2="0" End If
    If strCurmnth3="" Then strCurmnth3="0" End If
    If strCurmnth4="" Then strCurmnth4="0" End If
    If strCurmnth5="" Then strCurmnth5="0" End If
    If strCurmnth6="" Then strCurmnth6="0" End If
    If strCurmnth7="" Then strCurmnth7="0" End If
    If strCurmnth8="" Then strCurmnth8="0" End If
    If strCurmnth9="" Then strCurmnth9="0" End If
    If strCurmnth10="" Then strCurmnth10="0" End If
    If strCurmnth11="" Then strCurmnth11="0" End If
    If strCurmnth12="" Then strCurmnth12="0" End If
    'Calculate the YTD Amount
    strCurAmount = CDbl(strCurmnth1) + CDbl(strCurmnth2) + CDbl(strCurmnth3) + CDbl(strCurmnth4) + CDbl(strCurmnth5) + CDbl(strCurmnth6) + CDbl(strCurmnth7) + CDbl(strCurmnth8) + CDbl(strCurmnth9) + CDbl(strCurmnth10) + CDbl(strCurmnth11) + CDbl(strCurmnth12)
    Import_YTD =strCurAmount
    End Function

  • Columns adjustment in one row

    Hello,
    I hope some1 can help me for these.
    I am using apex 3.1.2 ver
    My first question: how can I put more columns for example 4 columns with heading in one row? when I do, screen is too wide but i do not want scrolling?
    e.g
    aaaaaaaaaaaaaaa( ) bbbbbbbbbbbbbb ( ) ccccccccccccccccc ( ) ddddddddddd( )
    second question?
    how can i display second column value based on first column value before saving the page?
    e.g. aaaaaaa(1) bbbbbbbb(should display text value based on first column)
    for example 1 - abc
    2 - def
    3 - ghi and so on.
    last question? how can i disable the column? should column enable based on other column? e.g if a then second column take value other disabled?
    Many thx.
    kind regards,

    Irha10 wrote:
    how can I put more columns for example 4 columns with heading in one row? when I do, screen is too wide but i do not want scrolling?In item property change "Begin on new Line " to "Yes"
    Irha10 wrote:
    how can i display second column value based on first column value before saving the page?01. You have to create a branch to same page
    02. Submit the page using any event (such as button press or something). So when you enter details to first item and then press button then page will submit and reload the same page.
    03. In the page create a before region process and check whether second item is not null and third item is null then populate third item. Then first item is not null and second item null then populate second item.
    Irha10 wrote:
    ? how can i disable the column? should column enable based on other column? e.g if a then second column take value other disabled?You can use a java script and enable and dissable item based on any condition such as value of another item
    Example
    if ($x('P16_YYY').value !='SOME VALUE')
      $x('P16_XXX').disabled = true;
    }else
      $x('P16_XXX').disabled = false;
    }

  • How to display Column data in one row

    Hello,
    I have one Employee with 4 effective date displayed in one column. Effective date is drived by Reason of : New Hire, Rehire, Transfer etc.
    I want to show the effective dates for one reason in one single row. For example a person was rehired 4 times it will show as
    1006555     6/12/2006     1/2/2007     6/11/2007     5/12/2008     12/29/2008     5/17/2010
    It's currntly showing as:
    AUDITEFFECTIVEDATE_3
    6/12/2006
    1/2/2007
    6/11/2007
    5/12/2008
    5/17/2010

    Well that's a little tougher... For a solution to work, you're going to need to find a way to differentiate between the the specific hiring events.  Without seeing what data is available, I'd say start looking at the use of running totals... or in this case a running count.
    Set it up to reset on EmployeeID and count each "event", incrimenting up with each instance.
    Then your formula would look more like this...
    IF {EventType} = "Rehire" AND {#RTotal1} = 1 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Exit" AND {#RTotal1} = 1 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Rehire" AND {#RTotal1} = 2 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Exit" AND {#RTotal1} = 2 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Rehire" AND {#RTotal1} = 3 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Exit" AND {#RTotal1} = 3 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Rehire" AND {#RTotal1} = 4 THEN AUDITEFFECTIVEDATE_3
    IF {EventType} = "Exit" AND {#RTotal1} = 4 THEN AUDITEFFECTIVEDATE_3
    This issue then becomes an issue of space on the report. You end up wasting 1/2 of your horizontal space trying to allot for one odd ball... You'll also get to re-work the report if the same employee goes for rounds 5, 6 or 7...
    HTH,
    Jason

  • Can I use one waveform to subtract from the other one in labview?

    Here is the thing.
    I am using DAQ to aquire amplified signal to measure its noise of output.However DAQ would contribute a little noise to the whole system.My thinking is to capture two waveforms of noise from DAQ itself and the whole system(amplified circuit and DAQ) and then make the subtration calculation between them.Is it possible to make it with labview?How?
    Or can I aquire two groups of signal using DAQ at the same time? If it can't be realised is there some other way?
    Thanks

    If I'm reading you right I don't think your original concept is valid.  If you have already done a good job with wiring, shielding, etc.  You won't be able to simply subtract a data collection of "just noise" from a collection of "noise plus signal" and expect the noise to cancel itself out.  It's random.  A better method would be to collect the same signal several times and then average the results.  Even that will only reduce repetitive components in the noise.
    As smercurio said however, the most important consideration is to make sure your connection method, grounding, shielding, timing, etc is top notch to prevent noise from contaminating the signal in the first place.  I generally use differential signals through good quality twisted pairs with the shield connected on the DAQ side only (to prevent ground loops).
    Using LabVIEW: 7.1.1, 8.5.1 & 2013

  • Multiple fact tables using one measure

    Hi Experts,
    Multiple fact tables using single measure .For example Measure name is amount . This measure is using 5 fact tables. By using this info , i have to create bmm layer document . In bmm layer documents columns are like logical table name ,column name, logical sourc name . could you please help me out to draft the document ?

    Hi ,
    My question is five fact tables are there, day level two different fact tables , period and week fact tables are there .
    Above all tables are using single measure . how to design these fact tables with measure in bmm layer ?
    Please kindly give reply .
    Thanks in advance.

  • How to subtract ith position of one array from the ith position of another

    Hi, everyone,
    In my program, I subract one array from another. It should be like X(i) - Y(i)
    Can someone explain to me how I can make sure that I'm subracting ith value of array 2 from the ith value of array one?  Not , for example, X(i)- Y(i+1)?
    Thank you
    Solved!
    Go to Solution.

    Hopefully, you are not doing anything more complicated than this:
    This does X(i) - Y(i).
    Message Edited by Dennis Knutson on 12-21-2009 10:59 AM
    Attachments:
    Subtract.PNG ‏2 KB

  • Want to Change the Column Indetn Color of Measure Label in a Pivot View

    Hello,
    I have used the measure labels in the "ROWS" of a pivot table and there is a column header or indent on the top these measure label which is BLUE by default .My requirement is to change that to a different color and if possible put some text there.
    (to be simple i see a .PTindent cell ,on the top of measure label which i want to edit from dashboard or reporting end without making any changes to the CSS entry files,becuase this entry can cause effect to all the table already in the environment)
    Thanks
    Raghu
    Edited by: user13136841 on Nov 22, 2010 11:56 AM

    Let's try this step by step:
    1) In your report add a Static Text view.
    2) Add the formula I described:
    <style>.PTIndentCell {background-color: #000000;}</style> 3) Check the "Contains HTML Markup" checkbox.
    View the Compound Layout or in the Dashboard (viewing the Pivot Table will NOT show the change.)
    If you can't see anything than the next thing to check is if you can view HTML. Go to a CHAR column and click on the Data Format tab. What choices do you see if you attempt to override the format? If you see HTML, then okay. If you don't, but only see "Plain Text," than HTML is not enabled. The default for OBIEE is to not allow HTML. You will need to change your instanceconfig.xml file and set the HardenXSS to false. See the link below:
    http://download.oracle.com/docs/cd/E12096_01/books/AnyWebAdm/AnyWebAdm_CustAnyWeb23.html

Maybe you are looking for