Ssrs MAX filter

hello i have rather a long query 9see below)which gives me data from various tables etc this bit works fine by the way !
what this does is it shows me the last(MAX) notebook entry (NotebookLinks.CreatedOn) and gives me the results filtered to the MAX date  which is fine, however if i then add the user who created the noteentry by adding the field  notelinks.createduser
i then lose the MAX filter and get all the notelinkdate and all the users! 
from what i have read its must be something to do with row.count or some thing along those lines! 
any ideas please !!
thanks in advance 
Company  date      term pname  psurname  con      
notelinkdate 
Test        
3
1
2013
 Perm
Chelsea
Parsons
  toms
   02/01/2014 14:49:45
Test
3
1
2013
 Perm
Haleh
Parsizadeh
 TOMS
   26/01/2011 19:36:45
Test
3
1
2013
 Perm
Jackie
Brobbey
 TOMS
    29/11/2010 16:36:17
Test
3
1
2013
 Perm
Jasmine
Ferres           
TOMS
   29/10/2013 12:42:23
Test
3
1
2013
 Perm
Jessica
Schnitzer
TOMS
  14/05/2013 13:10:43
Test
3
1
2013
 Perm
Karine
Schnitzer
TOMS
  14/05/2013 13:10:43
Test
3
1
2013
 Perm
Leah
Aldersley
TOMS
  17/12/2013 14:44:01
Test
3
1
2013
 Perm
Rajal
Mahida
TOMS
  08/01/2014 16:48:01
Test
3
1
2013
 Perm
Sarah
Nelmes
TOMS 
 14/05/2013 13:10:43
Test
3
1
2013
 Perm
Tess
Bethune
TOMS
 14/05/2013 13:10:43
Test
3
1
2013
 Perm
Vicky
Clarfelt
TOMS
  02/01/2014 14:49:58
SELECT     Clients.Company, COUNT(DISTINCT Jobs.JobRefNo) AS JobsOn, COUNT(DISTINCT Placements.PlacementID) AS Placements, YEAR(Jobs.CreatedOn) AS Year, 
                      EmploymentTypes.Description, Person.PersonName AS ContactName, Person.Surname, Users_1.LoginName AS ClientCon, MAX(DISTINCT NotebookLinks.CreatedOn) 
                      AS LastNoteCreated, Users.LoginName
FROM         Users RIGHT OUTER JOIN
                      NotebookLinks ON Users.UserId = NotebookLinks.CreatedUserId RIGHT OUTER JOIN
                      ClientContacts ON NotebookLinks.ObjectId = ClientContacts.ContactPersonId FULL OUTER JOIN
                      Person ON ClientContacts.ContactPersonId = Person.PersonID FULL OUTER JOIN
                      ClientConsultants RIGHT OUTER JOIN
                      Clients ON ClientConsultants.ClientId = Clients.ClientID LEFT OUTER JOIN
                      Users AS Users_1 ON ClientConsultants.UserId = Users_1.UserId ON ClientContacts.ClientId = Clients.ClientID FULL OUTER JOIN
                      EmploymentTypes RIGHT OUTER JOIN
                      Jobs ON EmploymentTypes.EmploymentTypeId = Jobs.EmploymentTypeId LEFT OUTER JOIN
                      Placements ON Jobs.JobId = Placements.JobID ON Clients.ClientID = Jobs.ClientId
GROUP BY Clients.Company, YEAR(Jobs.CreatedOn), EmploymentTypes.Description, Person.PersonName, Person.Surname, Users_1.LoginName, 
                      ClientConsultants.UserRelationshipId, Users.LoginName
HAVING      (YEAR(Jobs.CreatedOn) >= YEAR(GETDATE()) - 1) AND (EmploymentTypes.Description = N'perm') AND (Clients.Company LIKE N'itv%') AND 
                      (ClientConsultants.UserRelationshipId = 9)
Steve mason

As I understand, You want to display the data from the row in your dataset that represents the last (MAX) entry for a given note. Add another item to the SELECT list (and GROUP BY):
ROW_NUMBER() OVER (PARTION BY [Your Group fields] ORDER BY NotebookLinks.CreatedOn DESC) AS Row
this will add a sequential integer to each row of a group, assigning 1 to the most recent. Then just filter your report table:
Expression: [Row]
Type: Integer
Operator: =
Value: 1
"You will find a fortune, though it will not be the one you seek." -
Blind Seer, O Brother Where Art Thou
Please Mark posts as answers or helpful so that others may find the fortune they seek.

Similar Messages

  • SSRS dataset filter expression using OR

    I have a dataset that I need to set a filter for. What I need the filter to do is check 3 different fields to see if either one of them are in a parameter. The parameter is multi-value. So, I have a parameter set to 1, 2, 3. I need the dataset to return
    records where either Field A, B, or C are IN 1, 2, 3.
    Anyone know how to do this? I tried to have the filter expression = Fields!A.Value or Fields!B.Value or Fields!C.Value then the dataset filter operator "IN" and the dataset filter value = Parameter, but I just get an error on the dataset filter
    (cannot evaluate filter expression error)

    Hello,
    Mulitple expressions added to SSRS dataset filter are evaluated as AND (Expr1 AND Expr1 AND Expr3). If you are looking for a OR like Expr1 Or Expr2 Or Expr3 then you can use this solution explained below.
    Dataset Query used for this test:
    select *
    from (values ('Row1',1,1,4),('Row2',2,1,3),('Row3',3,1,2),('Row4',3,2,2),('Row5',5,3,2),('Row6',5,6,7),('Row7',2,6,7)) x(DataRow,A,B,C)
    Report Parameter :
    Defined a multi select report parameter named "Parameter1" with string datatype and added values 1, 2, 3.
    Dataset Filter Expression:
    =Filter(Parameters!Parameter1.Value,CStr(Fields!A.Value)).Length + Filter(Parameters!Parameter1.Value,CStr(Fields!B.Value)).Length + Filter(Parameters!Parameter1.Value,CStr(Fields!C.Value)).Length
    The expression above uses the Filter function in SSRS to check if the field A\B\C has any match in the parameter1 mutli select parameter. If yes the length property will return a value > 0. Repeat the expression for all the other fields and add the Values
    for length property.
    Use > operator in the filter dialogue box
    and value as 0 as shown in the snapshot below.
    The output is shown below. Row 6 is missing as Field A, B or C doesnt have 1, 2,3 as values. If this is the output you are looking for this solution should work for you.
    --sIbu

  • SSRS Dataset Filter expression query

    I have an SSRS report which has a simple dataset and accepts two date parameters, and filters the results based on a Position parameter. The Position parameter filter is:
    Expression: Position
    Operator: In
    Value: [@Position]
    I have now been told that each position has a few other aliases in the database against the Position column. i.e. For a Position of "Contractor" I now also need to return "Consultant" records, based on the same field. Note, only one Position
    can be selected at a time.
    I imagine I have to update the Value expression above to do something like:
    - When @Position in "Contractor" also return rows where Position is x, y, z (I am happy to hard code these)
    I have about 10 Positions each with one or more aliases - can someone help guide me on how to set up the expression?
    Thanks!

    Thanks Ione.
    Ok - I have set my parameter values in the value box, comma separated
    My dataset filter for the param Operator is set to IN and the value [@Position]
    However where I have multiple values set against a position I do not get any results (there is data in the DB)
    Do I need to do something different when setting the paramter values? i.e. use the expression and then a function to parse the comman separted values
    Or - something in the Filter to make the expression parse the incoming paramter?
    Thanks again

  • SSRS Dataset Filter Operator

    Hi --
    I have a Dataset which returns data based on a multi select parameter. It uses a filter to achieve this and works as expected (based on the IN Operator).
    Now I have to update the report so it also returns records for this parameter value which are NULL - Is it possible to achieve this using an expression/filter within the report, or do I have to get the DBA's to review and update the back-end stored
    procs?
    Thanks

    Thanks Visakh16 -- Sorry, but to add to this..
    I need to allow the user the option to include blank values, or not. Therefore I have added a new parameter "also include blank projects", a yes/no drop down.
    I currently bring back the complete dataset, which is then filtered by the multi select projects param - but how do I get the new parameter ("include blank records") to bring back the selected projects AND records where the Projects field is NULL
    if the new param is equal to Yes?

  • Flicker free or de-interlace filter

    I can't seem to find a flicker free or de-interlace filter?

    moze, that's correct.... the project (timeline) needs to remain interlaced. I've placed a few lower thirds which were created in PS and imported as png.
    Doing this in FCP 7 I'd then add the "Flicker Filter MAX" filter which eliminated flickering when played back on a interlaced TV.
    hafken - Thanks for that advice, I've only just bought the Ripple Traning Motion 5: Rigging & Publishing Titles, Transition, Effects & Generators for Final Cut Pro X, so I'll go through that and try work this out.
    Cheers to all once again.

  • Report Not working in the Web Browser

    Hi ALL ,
    Am working on a item SKU report . The report is running fine in the BIDS but once i try to view the report in the WEB Browser
    tried both Mozilla and Internet Explorer no data is shows up .
    The report has 2 report filter one is on the service and the other one is the item sku its a multi - parameter  that contains
    a list of more than 6000 different SKU . Can the filter be the reason for the report not displaying in the web browser.
    If yes kindly advice me what the workaround for it .
    I tried having the filter in the  SQL main query but it was of no use no data it was showing after having the ssrs report filter
    at least right information its showing but in the BIDS not in the main web browser.
    Kindly Help
    Priya

    Hi Priya,
    According to the description, I understand that there are parameters (@SKU and @SKUlist) in the report, and SKUlist parameter is multi-value parameter. When selecting values of the SKU parameter, the parameter SKUlist will display corresponding values. In this
    case, you should create cascading parameters, right? And you use parameters to filter the report.
    Because the data of the report can be shown in the Business Intelligence Development Studio (BIDS) environment, the issue only occurs after deploying the report to report server. Based on my research, I think it may occur because of web browser issue. I have
    known you use Mozilla and Internet Explorer to view the report but there is still no data.
    In Reporting Services, not all report functionality is supported by all browsers. In this scenario, I suggest you considering the aspects of the setting or third party add-ons of Internet Explorer (IE). You can refer to the steps below:
    1. Click Tools -> Internet options.
    2. Switch to the Security tab, click Local intranet, and then select Default level.
    3. Switch to the Advanced tab, and click Restore advanced settings.
    4. Temporarily disable third party add-ons. For detailed steps, please see the link:
    http://windows.microsoft.com/en-IN/internet-explorer/manage-add-ons#ie=ie-10
    Reference:http://technet.microsoft.com/en-us/library/ms156511(v=sql.105).aspx
    Regards,
    Heidi Duan
    Heidi Duan
    TechNet Community Support

  • How do I modify the "Number of Pages" setting for an existing Master Page via javascript?

    I'm learning javascripting for InDesign and I have been tinkering with the stock scripts in the tutorials. I'm developing the ability set properties and such, playing with how Javascript works, and I wanted to change the number of pages in a master page as part of an exercise. Does anyone know how to do this? I have been able to add new masters, controlling the number of pages in them with this:
    myDocument.masterSpreads.add( {pagesPerSpread:2,} )
    but what I really want is to modify the master that InDesign automatically generates with a new document, to have 2 pages. Granted, I can just start off with a document with facing pages, but I don't really see the fun in that...

    Jump_Over wrote:
    Hi,
    check this:
    var mSpread = app.activeDocument.masterSpreads[0],
    count = mSpread.pages.length,
    mSet = 2,
    run = mSet - count;
    // to avoid 0-page error
    mSet = Math.max(mSet,1);
    if (run > 0) {
              while (run --)
              mSpread.pages.add();
    else while (run) {
              mSpread.pages[-1].remove();
              run ++
    edit the variable mSet to modify pages length
    Jarek
    Message was edited by: Jump_Over I added Math.max filter to avoid errors
    Thanks, this is exactly what I wanted. Well, almost. I wish there were a way to simply set the number of pages in a master spread to a specific number the same way there is in the interface, but this will work just as well.

  • Repeat Column Value derived from formulae

    I need to repeat a value derived for a particular column &row combination to all rows in the table. however when I put the 'case' function it does not repeat the values as I expect. The value is only shown in the 1at row
    The formulae used is as follows
    CASE WHEN D_MILLS.MILL_NO =1 THEN (F_MILL_PRODUCTION.FN_YTD_CPO_PRODUCED/F_MILL_PRODUCTION.FN_YTD_CROP_PROCESSED ) ELSE (FILTER(F_MILL_PRODUCTION.FN_YTD_CPO_PRODUCED/F_MILL_PRODUCTION.FN_YTD_CROP_PROCESSED USING (D_MILLS.MILL_NO = 1.00)) ) END
    Note : Mill No is the Dimension Field that I user for the report. and I require the value of derived for mill No =1 to be repeated to all other mills (Mill No =2,3 etc)
    Edited by: Shaz01 on Aug 7, 2010 1:45 AM

    Hi,
    Use the formula like this,
    Max(CASE WHEN D_MILLS.MILL_NO =1 THEN (F_MILL_PRODUCTION.FN_YTD_CPO_PRODUCED/F_MILL_PRODUCTION.FN_YTD_CROP_PROCESSED ) ELSE (FILTER(F_MILL_PRODUCTION.FN_YTD_CPO_PRODUCED/F_MILL_PRODUCTION.FN_YTD_CROP_PROCESSED USING (D_MILLS.MILL_NO = 1.00)) ) END)
    Also for all the values you need to show the value of Mill no 1, so no need for case statement.
    MAX(FILTER(F_MILL_PRODUCTION.FN_YTD_CPO_PRODUCED/F_MILL_PRODUCTION.FN_YTD_CROP_PROCESSED USING (D_MILLS.MILL_NO = 1.00)))
    Thanks,
    Vino

  • Sync logic question

    Hey all,
    On one of the tables I am syncing up, I have some logic in the WinCE Template that only selects the record with the MAX calibration_number for a given Facility.
    So, if the following records are present in 8.1.7
    Facility Calibration_number
    AAA 11
    AAA 15
    AAA 20
    Only the 3rd record (AAA 20) will get copied to 9iLite. This is working as it should.
    However, if at a later date, a new record is entered in 8.1.7, say:
    Facility Calibration_nubmer
    AAA 25
    The next time a sync is done, this new record gets copied to the hand held (as it should), but the old record, which no longer meets the MAX filter in the WinCE Template still exists in 9iLite.
    It does not make a difference if I select Fast Refresh or Complete Refresh in the CE template.
    Is the sync working correctly? Does the WinCE Template only filter what gets copied to 9iLite from 8.1.7 and not what needs to be removed/changed from 9iLite as a result of changes to 8.1.7?
    If the sync is working as it should, is there anyway to accomplish what I am trying to do? i.e. automatically remove 9iLite records that no longer conform to the WinCE template filter.
    Thanks.
    Darren.

    Hi,
    Here what I am doing:
    I have a plan table and I am downloading the data which has a 0 in its DOWNLOADED_FLAG column. Of course I create the snapshot appropriate for this.
    CREATE TABLE MYPLAN_TABLE(
    MYCOLUMN VARCHAR2(10),
    CALIBRATION_NUMBER NUMBER
    DOWNLOADED_FLAG INTEGER,
    PRIMARY KEY (MYCOLUMN, CALIBRATION_NUMBER)
    MYPLAN_TABLE
    MYCOLUMN     CALIBRATION_NUMBER     DOWNLOADED_FLAG
    AAA           11               -1
    AAA           15               -1
    AAA           20               0
    In this situation the only data which will be downloaded to the client is the last one. Then you must update it and set the DOWNLOADED_FLAG column to -1 and redo the sync operation
    This operation updates the existing data in the Oracle db server and deletes the record in the client.
    But here I make the sync operation in 2 seperate steps:
    -First step sends the data to the server.
    -Second downloads the new data.
    After these think that you have added new record to the table in the db server (like the one below, AAA 25):
    MYPLAN_TABLE
    MYCOLUMN     CALIBRATION_NUMBER     DOWNLOADED_FLAG
    AAA           11               -1
    AAA           15               -1
    AAA           20               0
    AAA           25               0
    Then start the sync operation. At last, the last view of the table is like this
    MYPLAN_TABLE
    MYCOLUMN     CALIBRATION_NUMBER     DOWNLOADED_FLAG
    AAA           11               -1
    AAA           15               -1
    AAA           20               -1
    AAA           25               0
    and you have only the last record in the client database.
    If I can not tell this briefly please send me an e-mail. Nowadays I use this type of operation in a project and it is working fine.
    Regards,
    Bogac OZGEN

  • Replacement airport express won't connect to internet

    Why can't I get my replacement airport express to connect to the internet

    Wonder if you can direct me to any past or present solutions. I have the new Airport Extreme tower. Actually I'm trying number 2 thinking the problem was number 1. Apparently not. I've done multiple factory resets. Even waited couple hours to try reinstall because my provider said there is a Mac or max filter and wait. Anyhow once I'm able to get the AE online(green) not internet connection. I brought my Airport express in and hooked it up and in blink of an eye it's online with internet. Even phone companys stock modem connects. Interesting that the A express summary lists the DNS addresses and domain. Took this information and tried putting it in when retried the AE. No luck. The First  AE worked for over week. Phone tech checked switch at office and did line ping.
    My DSL provider uses DCHP.Sorry I forgot the name of the box outside at my phone line where DSL connects. Inside I make connection phone jack and ethernet cable.
    As I said I've done every form of power down reset. Any suggestion be appreciated. Next stop be Apple.

  • SSRS report with tabular model - MDX query to filter parameter data based on Tuple value.

    Hello Everyone,
    I am working on SSRS report in which a tabular model is being used as a backend.
    I want to filter the report parameters which are dependent to other parameters. Like, country, state, and cities drop downs.
    All are multi-select parameters. I am using MDX queries to filter the parameters data.
    Based on selected one or more countries, the data of states needs to be filtered.
    The point is the text which is being displayed in state dropdown for each state name is combination of 3 different members.
    So, I created the following Tuple for the same and can see the expected display names in states dropdown.
    "("+
    [Location].[Code 1].CURRENTMEMBER.UNIQUENAME +","+
    [Location].[Code 2].CURRENTMEMBER.UNIQUENAME +","+
    [Location].[Descr].CURRENTMEMBER.UNIQUENAME +")"
    Now, when I would like filter the cities data based on selected one or more states, I am unable to pass the multiple Tuples (more than one selected Tuples) as parameter for cities dropdown.
    The following is my query for City parameter. It is working well when I select only one State from the dropdown.
    However, when I select multiple states, it is unable to convert the Tuple into SET in ELSE part of IIF condition specified in following query.
    Can anybody help me how to resolve the error that I am getting about STRTOSET function?
    Or
    Are there any other alternatives to achieve this requirement?
    Any help would be much appreciated.
    Query:
    WITH MEMBER [Measures].[ParameterCaption] AS [City].[City Business].CURRENTMEMBER.MEMBER_CAPTION
    MEMBER [Measures].[ParameterValue] AS [City].[City Business].CURRENTMEMBER.UNIQUENAME
    MEMBER [Measures].[ParameterLevel] AS [City].[City Business].CURRENTMEMBER.LEVEL.ORDINAL
    SELECT {[Measures].[ParameterCaption], [Measures].[ParameterValue], [Measures].[ParameterLevel]} ON COLUMNS ,
    [City].[City Business].Children ON ROWS
    FROM (
    SELECT ( STRTOSET(@State, CONSTRAINED) ) ON COLUMNS FROM [Model])
    WHERE ( IIF( STRTOSET(@State).Count= 1,
    STRTOTUPLE(@State, CONSTRAINED),
    STRTOSET("{
    ("+
    [Location].[Code 1].CURRENTMEMBER.UNIQUENAME +","+
    [Location].[Code 2].CURRENTMEMBER.UNIQUENAME +","+
    [Location].[Descr].CURRENTMEMBER.UNIQUENAME
    + ")
    }",CONSTRAINED )) ) CELL PROPERTIES VALUE
    Thanks, Ankit Shah
    Inkey Solutions, India.
    Microsoft Certified Business Management Solutions Professionals
    http://www.inkeysolutions.com/MicrosoftDynamicsCRM.html

    Hi,
    I used following dynamic query in expression of dataset of parameter and it works like a charm.
    "WITH MEMBER [Measures].[ParameterCaption] AS [City].[City Business].CURRENTMEMBER.MEMBER_CAPTION "&
    "MEMBER [Measures].[ParameterValue] AS [City].[City Business].CURRENTMEMBER.UNIQUENAME "&
    "MEMBER [Measures].[ParameterLevel] AS [City].[City Business].CURRENTMEMBER.LEVEL.ORDINAL "&
    "SELECT {[Measures].[ParameterCaption], [Measures].[ParameterValue], [Measures].[ParameterLevel]} ON COLUMNS , " &
    "[City].[City Business].Children ON ROWS " &
    " FROM [Model] WHERE ({"& join(Parameters!Location.Value,",") &"}) CELL PROPERTIES VALUE"
    Thanks, Ankit Shah
    Inkey Solutions, India.
    Microsoft Certified Business Management Solutions Professionals
    http://www.inkeysolutions.com/MicrosoftDynamicsCRM.html

  • Problem with passing 2 or 3 members from filter to drillthrough report (SSRS report) in PPS

    Hi,
    I have one dashboard and one filter in PPS. Dashboard contains one main analytical chart report-- sales by Product category and the filter name is Year (contains the members values from 2005 to 2014).
    I have one more drillthrough report--- Detailed report for sales by product category (SSRS report)
    SSRS report having two parameters 1. year  (Multi selection) 2. Product category (single selection)
    Now, I have select 2006,2008 in the pps filter and analytical chart report rendered based on the filter values.
    next, on the analytical chart, I have selected on bar item (cars) out of 4 categories(Cars,Bikes,Trucks,Accessoreis) and right click -->drillthrough-->click on Detailed report for sales by product category.
    I have verified the ssrs detailed report and pps is passing only ALL member instead of passing 2006 and 2008 to the Year filter and Cars category members correctly passed to product category parameter from PPS.
    Note: If I have passed one member values (year=2006), pps is able to pass to ssrs report. But, it failed in two or more member values from filter.
    I have verified in sql profiler also. PPS passing ALL member to SSRS detailed report Year parameter.
    Please provide your suggestions. 
    Thanks,
    kishore

    sorry for the late updation.
    My First Report, Summary level is a Pivot Table.
    I tried the same report with Table option, the value is passing correctly.
    Is there a way to get rid of this situation using Pivot table.
    Thanks for your help.
    below is the original request.
    Hi,
    I am Hemanth, I have developed 2 reports. Firast Report High Level Summary, Secong is detailed. First report is developed using Union(4 union) , I am having 4 columns. The report is generating the data. I have used Navigation option on Client Column to move on to Second report. In Second report with in Filter i am using Prompted option. Due to some problem, the client value from first report is not passing to the second one. The second report is getting generated for all the clients.
    Normally i have used this Navigate option in other reports and that works fine. I have even tested with Union, it works. This time it is giving some trouble.
    Please, let me know whats going wrong.
    Thanks for the help.

  • Can I add a datetime filter to an expression in SSRS

    I am using SSRS to create a tablix that displays weekly, monthly and yearly values. My query contains data for the entire year. I would like to avoid creating 3 Datasets and then displaying three tables together (which I have already tried and did not like 
    because occasionally the current week or month does not have the same number of rows in the Tablix. )
    I am trying to create an expression that shows the Sum of the values
    Sum(Fields!Sale.Value)
    when the sales are equal  to the current week, month or year
    DATEPART(wk, sale_date) IN (DATEPART(wk, @week)
    DATEPART(month, sale_date) IN (DATEPART(month, @week)
    DATEPART (year, sale_date) IN (DATEPART(year, @week)
    Any ideas?

    Hi PrandyJosselyn,
    Per my understanding that you have an date field in table(Sale_date) and you want need to calculate the week sales, month sales, year sales based on this date, you need to filter the data of the yearly, monthly, weekly to display in the report based on the
    filter, right?
    I have testedon my local environment and you can modify the query in the main dataset as below to get add the week number, month number, year number if they didn't exists in the db, create three cacading parameter to display the values of "Year Number","Month
    Number","Week Number".
    Details steps below for your reference:
    1.Modify the query in the main dataset as below to add the filter of the three parameters:
    SELECT  Sale, Sale_Date, DATEPART(wk, Sale_Date) AS weeknum,DATEPART(month, Sale_Date) as monnum,DATEPART (year, Sale_Date) as yearnum
    FROM   tablename
    where DATEPART(year, Sale_Date) =(@YearNum) and  DATEPART(month, Sale_Date) =(@MonNum) and DATEPART(wk, Sale_Date) =(@WeekNum)
    2.Create and new DateSet2 and create Parameter1(YearNum) which get the values from this dataset and use this expression:
    SELECT     DATEPART(year, Sale_Date) AS YearNum
    FROM         TableName
    3.Create and new DateSet2and  create the Parameter2(MonthNum) get the values from this dataset and use this expression:
    SELECT    Distinct  DATEPART(month, Sale_Date) AS MonthNum
    FROM         TableName
    where   (DATEPART(year, Sale_Date) = @YearNum)
    4.Create and new DateSet3 and  create the Parameter3(WeekNum) get the values from this dataset and use this expression:
    SELECT    Distinct  DATEPART(wk, Sale_Date) AS WeekNum
    FROM         TableName
    where   (DATEPART(year, Sale_Date) = @YearNum) and (DATEPART(month, Sale_Date) = @MonthNum)
    5.Design the report to add group for the year and month:
    If you still have problem, please provide the sample data of the table in DB and the snapshot of the report structure you have designed. 
    Any problem, please feel free to ask.
    Regards
    Vicky Liu
    Vicky Liu
    TechNet Community Support

  • Is it possible to create a custom filter control in SSRS 2005?

    Hello!
    I need to make a custom filter control for my reports which will provide some options for date parameter:
    - year and month selection
    - Some RadioButtons: "Yesterday", "Today", "Tommorow", "Last week", "Next week"
    - Date range
    Please, give any suggestion which can help to solve this task.

    Vsevolod,
    Unfortunately there is no built-in support for this customization in SSRS so far. You have to code to implement this feature in your custom application. For example, use a ReportViewer control in an ASP.NET application or a Win Form application.
    Anyway I think that you promote a good suggestion to improve Microsoft product's feature. Could you please give your feedback to our product team here?
    https://connect.microsoft.com/sql
    Thank you.
    Please remember to mark the replies as answers if they help and unmark them if they provide no help

  • How to design SSRS report to filter multi-value parameter?

    I developed an RDL which takes a multivalue parameter and I want to set a visibility expression or filter based on this parameter. This parameter uses an "All" value equal to '660E4583-7F29-4D37-8038-5096AE6A1A7F'.
    I want to make the main tablix visible if this parameter is set to this uniqueidentifier and invisible otherwise. How can I achieve this either in the tsql dataset or on the report side? I have tried numerous workarounds, but none have worked so far! I've tried
    different expressions and datatypes.
    Before I tried If/Else statements in the tsql dataset, but most recently I instead added flags to the tsql dataset for each condition and am trying to make this tablix only include the records with the flag matching the parameters chosen. But even this is not
    working for me.
    Here is sample data:
    create table #dummydata
    parameter varchar(max),
    b varchar(max)
    insert #dummydata values('660E4583-7F29-4D37-8038-5096AE6A1A7F','record 1'),('660E4583-7F29-4D37-8038-5096AE6A1vcd','record 2'),('660E4583-7F29-4D37-8038-5096AE6A1v52','record 3')
    select * from #dummydata
    And my filter expression in the RDL for this tablix is:
    =iif(Parameters!Modifier.Value(0)="660E4583-7F29-4D37-8038-5096AE6A1A7F",1,0)
    With datatype = integer and value = 1 However, this tablix is invisible with the above even when I choose "All" for the parameter value = default value. How can I make this tablix visible?
    Ryan D

    Hi Ryan D,
    After testing the scenario in my local environment, everything goes well. As per my understanding, I think this issue can be caused by the Available values in the Modifier parameter. Could you tell us the Available values of Modifier parameter in your scenario?
    The following scenario in my test is for your reference:
    I create a dataset with the sample data you posted.
    Add a multi-value parameter named Modifier in the report.
    Specify the following values in the Available Values of the parameter (please note that the value “All” should be located in the first place, because we use Parameters!Modifier.Value(0) in the filter):
    Label: All                 Value: ="660E4583-7F29-4D37-8038-5096AE6A1A7F"
    Label: A                   Value: ="1"
    Label: B                   Value: ="2"
    Label: C                   Value: ="3"
    Drag a table to the design surface, insert parameter and b fields in the table.
    Use the same expression as you said to add a filter in the tablix.
    We can refer to the following screenshot:
    If there are any other questions, please feel free to ask.
    Thanks,
    Katherine Xiong
    Katherine Xiong
    TechNet Community Support

Maybe you are looking for

  • Plug in to Enterprise Portal Administration...

    Hello ! Could somebody tell me the plugin name to administration of the SAP Portal ???? Administration of users, roles, groups !! Regards. MBoni

  • Best practice to have cache and calclockblock setting?

    Hi, I want to implement hyperion planning. What should be the best practice to set essbase settings for optimize performance?

  • Invoices wrongly posted

    hi Friends, we have posted 2 invoices with a wong date on it future date 23 July. but the payment dates for these invoices were on 9th July. now the paymnets are already cleared by the payment run and the amount is already debited from the account. w

  • Padding a julian date with leading zeros ?

    Hi, I have gernerated a julian date, which I am appending to another two digit number to create a five digit serial number. Is there a simple way to pad the first 99 days with leading zeros ( i.e. 001, 002....025...099) so that I maintain a five digi

  • Restart gets stuck when downloading updates on MacBook Pro

    When I go into the Software updates on my Mac Book Pro, it says that all the updates are downloaded, but then when I hit restart, I get the big "space" screen and it doesn't do anything. It gets stuck there. Help!