SSRS Matrix report to show or hide year column based on parameter value "Date" selected.

Hey experts!
I have a requirement an ssrs matrix report should display columns (year/s) based on parameter value (date/s). 
My Dataset fileds are: Product, Year_name, Month_name, Date
Currently my report output looks like this-
Param Date: 2013-08-01 00:00:0.000
Product +Calender2011      +Calender2012     -Calender 2013........                        +Calender2014
                         Total
                  Total Jan13  Feb 13  Mar13..  Dec13   Total           Total
Abc                      100
                    220
10      20         30.......  20       250              400
Xyz 110
200 50      80         40.......  30       450              600
My requirement:  if I'm selecting Date parameter value as '2013-xx-xx' I should only able to see Year column 'Calender2013' and rest of the years should hide. Similarly If I'm selecting Date parameter value as '2014-xx-xx' I should only able to
see Year column 'Calender2014' .
Appreciate your kindly help. 
Afan

Hi Afan,
According to your description, you want to only show the selected year on your report, right?
In this case, you need to get the year from the date parameter using the expression below
=Year(Parameters!Date.Value)
And then use the expression below to get the year from Year_Name field.
=Right(Fields!Year_Name.Value,4)
Then add a filter to the dataset to filter the data like below
Expression:=Year(Parameters!Date.Value)
Operator:=
Value:=Right(Fields!Year_Name.Value,4)
Reference
http://msdn.microsoft.com/en-IN/library/dd255287.aspx
If you have any questions, please feel free to ask.
Regards,
Charlie Liao
TechNet Community Support

Similar Messages

  • Dispaly or Hide a column based on Prompt Value

    Hi All,
    How can I Display or Hide a Column based on Prompt Value selected?
    On my dashboard I have a Report/Request and a Dashboard Prompt.
    Dashboard Prompt has three values, say: *'A', 'B' and 'C'*.
    And my report/request has three columns named *'Field1', 'Field2'* and Field3'.
    What I am trying to achieve is that whenever user selects prompt values as *'A' or 'B'* all the three fields on my report named *'Field1', 'Field2' and Field3'* should be displayed, however whenever user selects prompt values as *'C'* only fields named *'Field1' and 'Field2'* should be displayed.
    Thanks,
    Deepak

    Hi Bhavna,
    I tried using View Selector, however I am not able to achieve the required functionality with that.
    I created a Request with 3 columns in it, then I switched to criteria and added another table to that. The new table automatically got the similar 3 columns used in the first report. Now when I tried to delete one of those columns from the new report, it also got deleted from the first report.
    All the views are dependent, changes made to one are reflected in other.
    Can't figure it out, where am I going wrong?
    Thanks,
    Deepak

  • Hide column based on parameter value

    Hi All,
    I have requirement where i need to hide one column based on my input parameter value.per example
    if my parameter say DISPLAY is Yes then i need to hide the column AMOUNT..
    how to achieve this... Please help.
    Thanks
    Bharat

    Hi Bharat,
    You can do it following the steps explained in the documentation :
    http://docs.oracle.com/cd/E12844_01/doc/bip.1013/e12187/T421739T481157.htm#4535373
    regards
    Jorge
    p.s. If this answers your question then please grant the points and close the thread

  • Hide a column conditionally to parameter value

    Hi experts,
    I'm new to Discoverer and I'm working with Disco 10.1.2.3.
    I need to hide a column conditionally to a parameter value, and I'm turning around for time.
    I can't find how to do this.
    I have tried few things with Conditional Formatting but unsuccessfully.
    If someone could give me a clue....
    Thanks in advance
    Brice

    Thanks Rod for your answer.
    I'm really sad to know that we can't hide a column in Discoverer, which for me seems to be a basic thing for such a tool.
    A Decode could be a good idea but the fields I would like to show/hide are part of hierarchies,
    and after few try I have seen that if I applied function on a field which is part of a hierarchy,
    Disco doesn't show it as a Hierarchy (I cannot Drill).
    That's why I was searching to put my 3 hierarchies fields and then hide 2 of them conditionally to a parameter value.
    If someone have an idea ...
    Thanks again Rod,
    Brice

  • Show new page table record based on parameter value in first page in ADF

    I have to show a selected record on a new page whose input query value is in first page. For example I choose to edit an order id  by selecting order id and then pressing Edit Record button then in new page selected order record should show. I am working in ADF JSF pages. I can pass parameter from one page to another by pageFlowScope. but how to display selected record on next page.

    any one to help. I want to use an input parameter on first page to edit the table on new page

  • Column limit in SSRS Matrix report being uploaded to Report Manager in SQL2008 R2

    Hi,
    I am getting this error :
    SQL Server Reporting Services
    Error
    The attempt to connect to the report server failed. Check your connection information and that the report server is a compatible
    version.
    I am attempting to upload my SSRS Matrix report to Report Manager. The report has a lot of columns (109 row columns followed by the variable number of column columns).
    After trial and error, I discovered that when I only have 107 row columns I can upload successfully.
    Can anybody explain why this is happening? Is there a limit of 107 columns?
    Thanks,
    GRustean

    As there was too much nesting in the tablix inside the report. We added new tablix and shifted some rows to that tablix. Because maximum of 36 level nesting is allowed in tablix

  • SSRS 2008 - hide chart lines based on parameter selected

    How to control visibility of chart lines based on Params selected by user?
    By default, my report display last 3 years worth of data (including current) with Month on the x axis and Counts on the y axis. I have two Boolean parameters:
    TwoYrs? T/F
    ThreeYrs? T/F
    if False is selected for TwoYr and ThreeYr parameters then I want to hide chart lines corresponding to last year and the year before.
    What I've tried: Created 3 Series groups with filters. eg. YearSeries1 to return only current year data and applying an expression to display it if params TwoYrs and ThreeYrs = False. and so on for YearSeries2 to return current + last
    years data if param TwoYrs is True and ThreeYrs = False.  But I don't see where to add expression to control the display of the individual series groups.  I am open to any way of doing this, but this seemed most logical.

    Hi Ok-Hee,
    In your Source Query just need to filter the series data based on the Parameters.
    I have written sample query below:-
    select * from
    select 1 monthnumber , 'Jan' MonthName, 2013 year,100 amount
    union
    select 1 monthnumber , 'Jan' MonthName, 2014 year ,200 amount
    union
    select 1 monthnumber , 'Jan' MonthName, 2015 year , 300 amount
    union
    select 2 monthnumber , 'Feb' MonthName, 2013 year, 300 amount
    union
    select 2 monthnumber , 'Feb' MonthName, 2014 year, 350 amount
    union
    select 2 monthnumber , 'Feb' MonthName, 2015 year,200 amount
    union
    select 3 monthnumber , 'Mar' MonthName, 2013 year, 380 amount
    union
    select 3 monthnumber , 'Mar' MonthName, 2014 year, 100 amount
    union
    select 3 monthnumber , 'Mar' MonthName, 2015 year, 500 amount
    )t
    where year in (
    select distinct FilterYear from
    select case when @TwoYrs=1 then year(getdate())-1 else year(getdate()) end FilterYear
    union
    select case when @TwoYrs=1 and @ThreeYrs =1 then year(getdate())-2 else year(getdate()) end FilterYear
    union
    select year(getdate()) FilterYear
    ) t
    I have created one post in my blog , you can check the result.
    https://msbitips.wordpress.com/2015/03/12/ssrs-2008-hide-chart-lines-based-on-parameter-selected/
    Thanks
    Prasad

  • Show or Hide empty table based on If condition

    I want to show or hide empty table based on condition. The table will be empty with 5 rows,2 cols and should display if <?Rout_Information1_id1?> is blank or null or when XML field is not present. Actually the JDEdwards report will generate XML file. In the XML file if <?Rout_Information1_id1?> is present it will have definitely value like 'PULL' or 'Cut' otherwise sometimes XML field itself will not be present. Need to display the empty table when the <?Rout_Information1_id1?> is not present. I am trying to do as below but the table is not displayed. Can someone tell me how to resolve this.
    <?if:Rout_Information1_id1=' '?>
    5 rows,2 cols table
    <?end if?>
    Thanks,
    Vijay Vattiprolu

    Ok. I used the below syntax from other post and it resolved displaying empty table issue.
    <?if:not(XML_TAG_NAME)?>
    <?end if?>
    Thanks,
    Vijay

  • Any standard report to show WBS,settlement, asset no and asset cost/value

    Hi All,
    Please advice . Is there any standard report to show WBS,settlement, asset no and asset cost/value ? I tried tcode kosrlist_pr but it does not show asset cost/value.. it shows only WBS,settlement and asset no.
    Thank you.
    Best Regards,
    Nies

    Dear,
    der is no such standard report to show WBS,settlement, asset no and asset cost/value as perv my knowlwdge. so do one thing select one standard report which is more similar to standard report to show WBS,settlement, asset no and asset cost/value but some of like asset no or asset cost or some other values not reflecting in that std report. den u take the Table name and field name of that particular fields which u wann reflect in the report. use the logic of STD TC of SAp which more similar to which u wanna preapre the New TC. tae help of Abaper. tell ur querry and content of ur report . he will definately do it
    if ur get my ans reward with points
    Regards
    Rakesh

  • Matrix report in XML publisher with dynamic column groups

    hi,
    i have one matrix report in txt format having 5 columns under 1 month heading.
    Now i want that all these 5 columns should repeat for multiple months depending upon input parameters.
    S. No.
    Organization Name
    Organization Id
    Project Code
    1
    GRANDWOODS 2
    6825
    1495
    month
    January
    Wrk Count Ven
    Wrk Cont Prw New
    Wrk Amt Ven New
    Wrk Amt Prw New
    Tot Amt New
    New
    0
    0
    0
    0
    0
    Existing
    0
    1
    0
    255000
    255000
    Total
    0
    1
    0
    255000
    255000
    rtf template is as follows:
    S. No.
    Organization Name
    Organization Id
    Project Code
    F CS_11
    ORGANIZATION_NAME
    ORGANIZATION_ID
    PROJECT_CODE E
    month
    Wrk Count Ven
    Wrk Cont Prw New
    Wrk Amt Ven New
    Wrk Amt Prw New
    Tot Amt New
    New
    F WRK_COUNT_VEN_NEW
    WRK_CONT_PRW_NEW
    WRK_AMT_VEN_NEW
    WRK_AMT_PRW_NEW
    TOT_AMT_NEW
    Existing
    F WRK_CONT_VEN_EXISTING
    WRK_CONT_PRW_EXISING
    WRK_AMT_VEN_EXISTING
    WRK_AMT_PRW_EXISTING E
    TOT_AMT_EXIS
    Total
    TOT_CONT_VEN_NEW_EXIS
    TOT_CONT_PRW_NEW_EXIS
    TOT_AMT_VEN_NEW_EXIS
    TOT_AMT_PRW_NEW_EXIS
    TOT E
    E
    now, please help me as to how repeat these 5 columns for multiple months.
    if anybody has some template for matrix report with multiple coloumn group repeatation, pls. share along with sample data.
    regards,
    mohit gupta

    Hi,
    Check this link for developing the matrix report
    Oracle Database and Oracle Applications: Matrix Report in XML Publisher
    Regards
    Srikkanth

  • How to hide table column based on country molga value

    Hi Experts,
    I am doing some enhancement in ess application. I want to hide table column based on country code i.e. Molga value.
    I want to hide coulm for only Japan country reset of them i need to be show those coulmn.
    Could you please provide me a sample code.
    Regards
    Chakri

    Hi Chakri,
    Your setting the table value that time you will get the Country Code.
    1.Create the attribute like Country_Column_Visible Data Type bind the com.sap.ide.webdynpro.uielementdefinitions.Visibility this value  you need to bind the table country column.
    2.In Table You need to check the country code Japan is available you need follow this below sample code.
    for(int i=0;i<tablesize;i++)
         tablesithValue=wdContext.nodeTable().getTablenode(i);
         if(null != tablesithValue.getcountrycode)
         if(tablesithValue.getcountrycode.equalsIgnoreCase("Japan"))
              wdContext.currentxxxxElement.setCountry_Column_Visible(WDVisibility.NONE);
         }else
              wdContext.currentxxxxElement.setCountry_Column_Visible(WDVisibility.VISIBLE);
    Use the above code you condition it will work.I hope it will help you.
    BR,
    Durga

  • How to Visible/Hide an Item based on the value of another Item

    Hi
    I need to visible and hide a textitem based on the value of another item.This form has 3 blocks, and the both item is in the first Master Block.
    My code is:
    if :RECORDTYPE=7 then
         Set_Item_Property('BLOCK.ITEM',VISIBLE,PROPERTY_TRUE);
         Set_Item_Property('BLOCK.ITEM',ENABLED,PROPERTY_TRUE);
    ELSE
         Set_Item_Property('BLOCK.ITEM',VISIBLE,PROPERTY_FALSE);
    Set_Item_Property('BLOCK.ITEM',ENABLED,PROPERTY_FALSE);
    :BLOCK.ITEM:=NULL;
    end if;     
    I wrote the code in the Validate Trigger, but not working when moving Next Record & Previous Record
    Thanks in advance
    Rizly

    Read the 'Propagation of Property Changes' section towards the end of the page for Set_Item_Property in the online help. I'm not sure what you mean by locking automatically but perhaps it's because of this.
    You should also ensure the item you're setting to invisible is not the current item (check :system.cursor_item and go to a different item if necessary).

  • SSRS Matrix report. Variance expression by Month. Need to compare month from prior year to current month of current year VS2010

    Please help.  I have a matrix report.  In the report I have row group  PO Type.  One the Column groups I have a parent group by Fiscal Year, and then a child group by Month.  When I run the report, I get two years of data back broken
    out by month.  Please see below.
    Now here is where I am getting stuck.  I need to take the variance between the current month of the current year, from the same month of the prior year.  So I need to show the difference between Oct , 2014 from Oct, 2013. November, 2014 from November
    2013... etc. etc.
    In the example below, how do I create a column or row showing the variance for Contracts for October 2014.  I need to take the contracts for October 2014 which is 3 and subtract that from October 2013 which is 8.  Any suggestions? How do I do that
    for each month?  Then I need to do it for the quarter... then the year?  But I'll be happy if I can just get the month working first.
    Any help will be appreciated. 
    here is what my rdl file looks like.
    Here is what my report looks like when I render it.

    Hi Adrian_s2012,
    According to your description, you want to compare values for the month of current year with the month of prior year and get the variance. Right?
    In Reporting Services, we don't have any function to get this "Year to Year" Growth. In this scenario, if you data source is a cube, we suggest you use Analysis Services to achieve your requirement. If this data source is just from database, it will be hardly
    to calculate the variance because we need to compare the values within every two different column group and matrix generate adjacent columns one by one. Even we make it by using custom, every time executing the long code when generating result
    in a cell will reduce a lot of performance, we really don't suggest to do that in SSRS. Here is a thread with much easier requirement, please take a reference of that:
    http://social.msdn.microsoft.com/Forums/office/en-US/842e2dcb-d949-4297-9d91-eac989692cb5/difference-between-the-grouped-column?forum=sqlreportingservices
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou

  • How to show or Hide Generic Column in a regular report

    Hi All,
    I have created report based on "SQL query (pl/sql function body returning sql query). It returns columns based on some conditions. I have total 60 generic columns like (COL1,COL2....COL60) but it returns 18 or 20 columns based on my conditions, how can I hide the columns that I don't needed. My column heading is based on function return by ':' separated. My function returns number of columns also. Is there any we I can show only those columns which contains data. My report is exactly similar to the default "SQL query (pl/sql function body returning sql query). I didn't find any logic how they are doing this show and hide. I appreciate any ones help.
    Thanks,

    Hi there,
    Somehow you need to find out how many columns your dynamic select will return (by what you said it seems that your procedure returns this information). Then store that number in a hidden page item, say Pnn_COUNT.
    Then, for the 19th and 20th columns in the report add these conditions:
    Column 19: :Pnn_COUNT >= 19
    Column 20: :Pnn_COUNT >= 20
    I hope this helps.
    Luis

  • SSRS Matrix Report

    Please see below matrix report before and after I run. How can I find percentage of below marked fields,
    for example: 1/3=0.33 (%33)  Female(PAs)/Total(PAs)=?
    Erdal Huzmeli

    Hi Erdal,
    According to your description, you have a matrix report and you want to get percentage of two different column in this report. Right?
    In Reporting Service, we can’t just use ReportItem function or aggregation function with scope string to calculation when we are working in a matrix because the columns of matrix are dynamic. So we need to define some functions in custom code and do calculation
    by calling those functions. Your scenario has been tested in our local environment. Here are some steps and screenshots for your reference:
    Add the custom code below into your report:
    Dim Shared Num1 As Integer
    Dim shared Num2 As Integer
    Public Function GetPA(PA as Integer, Type as String) 
    If Type = "Male" Then
       Num1=PA
    ELSE If Type="Female" Then
       Num2=PA
    End If 
    Return PA 
    End Function
    Public Function GetMalePct()
    Return Num1/(Num1+Num2)
    End Function
    Public Function GetFemalePct()
    Return Num2/(Num1+Num2)
    End Function
    Ps: We notice that Total PA=Male PA +Female PA. So we use “Num1+Num2” in the functions that we define in the custom code instead of using “SUM(Fields!PA.Value)” in expression.
    Put the expression below into the PA textbox in Gender group:
    =Code.getPA(SUM(Fields!PA.Value),Fields!Gender.Value)
    Put the expression below Female textbox within Gender Percentage:
    =Code.getFemalePct()
    Put the expression below Male textbox within Gender Percentage:
    =Code.getMalePct()
    Save and preview, the matrix and result looks like below:
    Reference:
    Custom Code and Assembly References in Expressions in Report Designer (SSRS)
    How to calculate the Percent change in a dynamic
    If you have any question, please feel free to ask.
    Best Regards,
    Simon Hou

Maybe you are looking for

  • Odata and Input Parameters

    Hello Experts, I have an Odata Service with multiple Input Parameters. I am creating a Dialog to allow user to enter values for Input Parameters and then show my Odata Model in a Table. I have two questions: 1.) I will create a dialog that will conta

  • Chinese characters in Forms 6i

    Hi Gurus, What are the settings required to enter Chinese characters in Forms 6i runtime. I am able to type chinese in MS Word. but when i type in Chinese in Forms i get ???????. Any help would be appriciated.

  • HT2731 Can u help me please

    I need help

  • Profit Center Substitution in Sales order

    Hello All, I have a Small Issue here. we have a substitution rule for the PCA Derivation in the SO with the combinations of few Sales Org, Distribution Channels and Divisions. But when a WBS Element is Assigned in the Sales order it is over writting

  • Choose only One bluetooth device to wake the mac.

    Hello, recently I have been having a unacceptable bt keyboard problem. This keyboard (3x AA model) with updated firmware, disconnects itself from my mac when my mac is sleeping and wakes it up with a "connection lost" It normally starts to happen whe