fetchxml を使用して作成されたレポートに動的パラメーターを渡そうとすると、問題が発生します。BIDS でレポートのプレビューを表示すると、パラメータ値を入力でき、レポートは正常に機能しますが、CRM オンラインからレポートを実行しようとすると問題が発生します。レポートは CRM の「アカウント」と「アカウント プラン」の値を選択していないようで、レポートは空です。参考までに、「アカウント プラン」は私が作成したカスタム エンティティです。誰かが時間を割いて、この問題を解決する方法について意見/提案を提供していただければ幸いです。
これが私のfetchxmlレポートからの情報です...
次のレポートとクエリ パラメータをレポートに追加しました:-
<QueryParameters>
<QueryParameter Name="@CRM_FilteredAccount">
<Value>=Parameters!CRM_FilteredAccount.Value</Value>
</QueryParameter>
<QueryParameter Name="@CRM_FilteredAccountPlan">
<Value>=Parameters!CRM_FilteredAccountPlan.Value</Value>
</QueryParameter>
</QueryParameters>
文字列 CRM_FilteredAccount 文字列 CRM_FilteredAccountPlan
これはルートエンティティタグです:-
<entity name="account" enableprefiltering="true" prefilterparametername="CRM_FilteredAccount">
ここで、次のフィルターを使用しています:-
<filter type="and">
<condition attribute="statecode" operator="eq" value="0" />
<condition attribute="name" operator="eq" value="@CRM_FilteredAccount" />
</filter>
これはリンク実体タグです:-
<link-entity name="opt_accountplan" from="opt_account" to="accountid" visible="false" link-type="outer" alias="accountplan" enableprefiltering="true" prefilterparametername="CRM_FilteredAccountPlan">
ここで、次のフィルターを使用しています:-
<filter type="and">
<condition attribute="statecode" operator="eq" value="0" />
<condition attribute="opt_name" operator="eq" value="@CRM_FilteredAccountPlan" />
</filter>