I am working on an SSRS report which takes two parameters, both a lookup reference to the Account entity. One of these parameters is a multi value (Attachment Owner) and the other a single value (Pole Owner). I have this report working using a Fetch XML (See below). The report works if I only select a single value for the Attachment Owner, however if I select more than one value the report throws an error. After some testing it appears the FetchXML does not like the comma deviated list of GUIDS provided by the multi value parameter. Is there another approach I should be looking at or am I doing something wrong with this approach?
In the below FetchXML statement I am specifying the Attachment Owner parameter inside a single 'in' condition inline:
<condition attribute="varju_owner" operator="in" value="@attachmentOwner"/>
I have also tried defining this condition as a multi line declaration with the same result:
<condition attribute="varju_owner" operator="in">
<value> @attachmentOwner</value>
</condition>
Here is the full FetchXML statement that is giving me errors:
<fetch version="1.0" output-format="xml-platform" mapping="logical" distinct="false">
<entity name="varju_attachment">
<attribute name="varju_attachmentid" />
<attribute name="varju_name" />
<attribute name="createdon" />
<attribute name="varju_type" />
<attribute name="varju_owner" />
<attribute name="varju_installationdate" />
<order attribute="varju_name" descending="false" />
<filter type="and">
<condition attribute="varju_owner" operator="in" value="@attachmentOwner"/>
</filter>
<link-entity name="varju_pole" from="varju_poleid" to="varju_pole" link-type="inner" alias="a_c48dfd112a07eb11a812000d3a8c999a">
<attribute name="varju_owner" />
<attribute name="varju_polenumber" />
<attribute name="varju_altpolenumber" />
<filter type="and">
<condition attribute="varju_owner" operator="eq" value="@poleOwner"/>
</filter>
</link-entity>
</entity>
</fetch>