Column group tablix, how to keep certain value in line

  • Hi, all

    I have that data and I group it by YearID in column group, but I need to keep value for given Period separately, so let say if @param = 201304, then I need to have Column < 201304 with value '444',

    I tried to put his Expression into column but it still pick up first value in ds = 4200, is it possible to achieve this inside rdl ?

    Appreciate your help.

    Best Mario

    /* this is desired output on rdl:

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

    CustIDName 2013 2014 201304

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

    12345Alpha 999 8500 444

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

    */

    -- declare @param int = 201304

    --=Iif(Fields!Period.Value = Parameters!Param.Value,Fields!Earnings.Value,111) -- doesn't work

    select '12345' CustID,

    'Alpha' Name,

    2014 YearID,

    4200 Amt,

    201402 Period

    UNION

    select '12345' CustID,

    'Alpha' Name,

    2014 YearID,

    4300 Amt,

    201403 Period

    UNION

    select '12345' CustID,

    'Alpha' Name,

    2013 YearID,

    222 Amt,

    201302 Period

    UNION

    select '12345' CustID,

    'Alpha' Name,

    2013 YearID,

    333 Amt,

    201303 Period

    UNION

    select '12345' CustID,

    'Alpha' Name,

    2013 YearID,

    444 Earnings ,

    201304 Period

  • Mario,

    Just wondering, but why do you have Earnings and Amount in the same column? If you separated them so that they were in separate columns, it would make dealing with the column a lot easier. you could create a calculated column in your data set and you would be sorted, right?

    In a nutshell, you could "merge" the two columns (add them or whatever) using IIF() But having the two values with different meanings in the same column looks like is the root of your problem, if I understand it right.

    HTH,

    Pieter

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply