FetchXML中的日期参数

2 dynamics-crm reporting-services ssrs-2008 fetchxml dynamics-crm-2011

我在SSRS 2008中使用FetchXML来创建CRM 2011的报告.我想在报告中包含参数,以便您可以显示From Date - To Date之间的记录.这是我到目前为止的查询.

<fetch>
      <entity name="appointment">
        <attribute name="scheduledstart" />
        <link-entity name="systemuser" from="systemuserid" to="ownerid">
            <attribute name="firstname" alias="ownerFirstName" />
            <attribute name="lastname" alias="ownerLastName" />
        </link-entity>
        <link-entity name="contact" from="contactid" to="new_contactperson">
            <attribute name="parentcustomerid" alias="parentaccount" />
            <attribute name="new_businessunit" alias="businessunit" />
        </link-entity>
        <attribute name="new_contactperson" />
        <attribute name="subject" />
        <attribute name="new_coldernotes" />
    <link-entity name="activityparty" from="activityid" to="activityid">
    <attribute name="participationtypemask" alias="participationtypemask" />
        <filter>
        <condition attribute="participationtypemask" operator="eq" value="9" />
        </filter>
        <link-entity name="systemuser" from="systemuserid" to="partyid">
            <attribute name="fullname" />
        </link-entity>
    </link-entity>
    <order attribute="scheduledstart" descending="true" />
      </entity>
</fetch>
Run Code Online (Sandbox Code Playgroud)

我怎么做到这样我可以在日期之间过滤?

谢谢!

Pet*_*eed 5

不确定您是否可以访问本机CRM客户端,但"高级查找"视图可以快速生成此示例FetchXML:

<filter type="and">
  <condition attribute="modifiedon" operator="on-or-after" value="2011-10-04" />
  <condition attribute="modifiedon" operator="on-or-before" value="2011-11-13" />
</filter>
Run Code Online (Sandbox Code Playgroud)