locked
MS CRM 2011 Custom report - how to include filter values in to report RRS feed

  • Question

  • If want to filter a report based on creation date, that is very simple. But how can I include that filter parameter into the report.

    If want to filter a report between two dates, I want to show those dates also on the report, how can I do that?

    Monday, January 20, 2014 9:49 AM

Answers

  • This has been solved!

    I use two normal text fields which both show created on date. Another shows max value and other shows min value.

    I think this is the easiest way.

    • Marked as answer by crm-user-crm Monday, January 27, 2014 12:05 PM
    Monday, January 27, 2014 12:05 PM

All replies

  • Hi,

    If it's is a custom report, you can use Parameters!FilteredAccount.Value

    where  FilteredAccount is the name of your parameter.

    Based on your scenario, you can call it in your report  like text box....





    VidhiyaM


    • Edited by VidhiyaM Monday, January 20, 2014 10:37 AM
    Monday, January 20, 2014 10:30 AM
  • Hi,

    following fetchXMl script will be helpful for you.

    <fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="false">
    	<entity name="contact">
    		<attribute name="fullname" />
    		<attribute name="telephone1" />
    		<attribute name="contactid" />
    		<attribute name="createdon" />
    		<order attribute="fullname" descending="false" />
    		<filter type="and">
    			<condition attribute = 'createdon' operator='between'>
    				<value>@parameter1</value>
    				<value>@parameter2</value>
    			</condition>
    		</filter>
    	</entity>
    </fetch>

    Where @parameter1 and @parameter2 are your parameters for dates.

    If my this is helpful for you then don't forget to mark as answer.

    Monday, January 20, 2014 11:50 AM
  • Hi,

    If it's is a custom report, you can use Parameters!FilteredAccount.Value

    where  FilteredAccount is the name of your parameter.

    Based on your scenario, you can call it in your report  like text box....





    VidhiyaM


    When I go to the expression menu, then category and then parameters, I have only one parameter, Parameters!CRM_FilteredSalesOrder.Value. Should I use that?
    Monday, January 20, 2014 12:21 PM
  • Hi,

    Yes,You should use that for displaying the value of the parameter.

    Parameter will display all the parameters used in the report(rdl)


    VidhiyaM

    Monday, January 20, 2014 12:52 PM
  • Hi,

    Yes,You should use that for displaying the value of the parameter.

    Parameter will display all the parameters used in the report(rdl)


    VidhiyaM

    When I used that, I only got this:

     
    <fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="false"><entity name="salesorder"><all-attributes /><filter type="and"><condition attribute="customerid" operator="eq" uiname="Account name" uitype="account" value="{F58E293F-F05B-E311-A900-00155D08231D}" /></filter></entity></fetch>
     
     

    Tuesday, January 21, 2014 7:51 AM
  • I still didn't get this to work!

    Can someone provide a step by step guide how to do this?

    Friday, January 24, 2014 11:13 AM
  • This has been solved!

    I use two normal text fields which both show created on date. Another shows max value and other shows min value.

    I think this is the easiest way.

    • Marked as answer by crm-user-crm Monday, January 27, 2014 12:05 PM
    Monday, January 27, 2014 12:05 PM