Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
smathers
Frequent Visitor

Dealing with Multi Value fields (ie Multi-select list or picklist)

Hi, I have seen a post similar to what I am dealing with in regards to Sharepoint and it seems PBI does cater for multi-value sharepoint fields  but I gather its Sharepoint specific. I have data that has come in from Salesforce and there is a multi-Select picklist field I need to report on. I am able to filter the table data based on their being a value selected in the picklist field. For instance if the user has selected,  Australia, New Zealand, New Guinea, Singapore (and this is how the selections are saved in the field, seperated by commas), I can have a filter filter the data for each of these countries and the record for the user/day will display.

 

What a manger wants however is to see the total countries selected for a designated period. So they need to see that Australia + New Zealand + New Guinea + Singapore was supplied on that day. So the data needs to come out as

Australia  = count of 1

New Zealand = count of 1

New Guinea = count of 1

Singapore = count of 1

I think I need to build a virtual table (User, Date, Individual picklist value) to handle this, but I am really interested in how others have dealt with reporting (not filtering) on multi-slect list fields.

4 REPLIES 4
v-lili6-msft
Community Support
Community Support

hi, @smathers

After my test, Does that suit your needs?

When I select B/D/E

13.JPG

Step1:

Use Values to create a fact table

Table = VALUES(Table1[Type])

14.JPG

Step2:

Create the relationship with basic table

15.JPG

Be careful Cardinality and Cross filter direction must like this

Step3:

Add the measure

Measure 2 = IF(SELECTEDVALUE('Table'[Type])=SELECTEDVALUE(Table1[Type]), CALCULATE(COUNTA(Table1[Type])))

Step4:

16.JPG

and right click Type set Show no Item data

17.JPG

 

here is demo pbix, please try it.

https://www.dropbox.com/s/vvvtdwe4mh5gnbt/Dealing%20with%20Multi%20Value%20fields%20%28ie%20Multi-se...

 

 

If not your case, Could you please share some sample data with the data structure and expected output. You can upload it to OneDrive or Dropbox and post the link here. Do mask sensitive data before uploading.

 

 

 

Best Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi Lin

Thanks for going to the trouble to make that file and provide screenshots. I really appreciate it. I loved the way that multi-Select control worked with PBI, however its not quite what I was looking for.  The Multi-select list data I have in PBI is brought into the PBI file from Salesforce live link. The users of the PBI reports are not going to be selecting any values...they want to see a report on what others have been up to when visiting schools and providing resources which they enter in Salesforce.

 

I am going to give a screenshot below of the data table on the left and the report output the manager wants on the right. It is identical to the output in your example however my input is different. I cannot get away with using "IF SELECTEDVALUE(" as my resource values are not distinct for each record.

Data on left is live dataData on left is live data

 

 

hi, @smathers

After my research, for your data source is live connection, It could be achieved for now. all the values is in the one field and It needs to be split. Your requirement needs to be the data source or get data by Import.

and I have a kind of method for you to refer to.

For example:

Step1:

In the Edit Queries, select RESOURCES Provided column then duplicate this column.

1.JPG

Step2:

Select the duplicate column then click Transform->Split Column->By delimiter

2.JPG

Step3:

select basic column then right click select Unpivot other columns

3.JPG

get 

4.JPG

Step4:

Close&Apply and create a measure

times = CALCULATE(COUNTA(Table1[Value]))

Result:

5.JPG

here is pbix, please try it.

https://www.dropbox.com/s/vvvtdwe4mh5gnbt/Dealing%20with%20Multi%20Value%20fields%20%28ie%20Multi-se...

 

Best Regards,

Lin

 

 

 

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi

I am in a similar situation and that solution I thought of myself, but my problem is that I also has a value attached. So in a normal fact I will have one line pr. value, but transposing it as You do creates multiple values and then the sum will be incorrect since I would sum the value as many times as the multianswer is reproducing the line.

 

How to do that?

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.