Skip Navigation LinksHome Page > Forums > SpiraTeam Forums > Spira Custom Reports > Multiselect list values d...
Hello,
I have been trying to modify a custom report which throws an error due to a multiselect list custom propery from test runs and have encountered a similar issue as described in the forum below:
https://www.inflectra.com/Support/Forum/spirateam/reports/2265.aspx
I've reviewed the KB that was linked in the responses to the forum (https://www.inflectra.com/Support/KnowledgeBase/KB638.aspx) and have attempted to include the join and the Contains, EndsWith and StartsWith set of functions to the report query. The report is no longer throwing the error when generated, however it is only displaying the first value when multiple values are selected. The KB seems to describe creating a graph and I'm wondering if since I'm updating a report instead does the XSLT template require a modification as well to allow these values to display separated by commas?
Here is the original query that was causing errors due to the custom property being a multiselect list:
--pulling in the Environment information from the LOVleft join(select SubC.CUSTOM_PROPERTY_VALUE_ID, SubC.NAMEfrom SpiraTestEntities.R_CustomListValues as SubCwhere SubC.PROJECT_ID = ${ProjectId}and SubC.IS_DELETED = False) as CB on CAST(R.CUST_02 as INT32) = CB.CUSTOM_PROPERTY_VALUE_ID
Here is what it was updated to:
--pulling in the Environment information from the LOVleft join(select SubC.CUSTOM_PROPERTY_VALUE_ID, SubC.NAMEfrom SpiraTestEntities.R_CustomListValues as SubCwhere SubC.PROJECT_ID = ${ProjectId}and SubC.IS_DELETED = False) as CB on Contains(R.CUST_02, Concat(Concat('0', CAST(CB.CUSTOM_PROPERTY_VALUE_ID as Edm.String)), ','))or EndsWith(R.CUST_02, Concat('0', CAST(CB.CUSTOM_PROPERTY_VALUE_ID as Edm.String)))or StartsWith(R.CUST_02, CAST(CB.CUSTOM_PROPERTY_VALUE_ID as Edm.String))
Also the XML code for the XSLT template for the value:
<th>Environment</th> <td><xsl:value-of select="Custom02"/></td> </tr>
Thank you.
And if you have any questions, please email or call us at +1 (202) 558-6885