Forum Discussion
Did something change with SelectionId, the key looks different now
Hi, this.host.createSelectionIdBuilder() service is not working properly anymore for me, did something change with they key, it looks different now. Now there is somekind of identityIndex in it.
key: used to be something like this ->
Key:"{\"data\":[\"{\\\"and\\\":{\\\"l\\\":{\\\"comp\\\":{\\\"k\\\":0,\\\"l\\\":{\\\"col\\\":{\\\"s\\\":{\\\"e\\\":\\\"qtEmergencyRecords\\\"},\\\"r\\\":\\\"Year\\\"}},\\\"r\\\":{\\\"const\\\":{\\\"t\\\":4,\\\"v\\\":2017}}}},\\\"r\\\":{\\\"comp\\\":{\\\"k\\\":0,\\\"l\\\":{\\\"col\\\":{\\\"s\\\":{\\\"e\\\":\\\"qtFacility\\\"},\\\"r\\\":\\\"Facility County\\\"}},\\\"r\\\":{\\\"const\\\":{\\\"t\\\":1,\\\"v\\\":\\\"Alachua\\\"}}}}}}\"]}
Any idea ?
It looks good to me.
What API version are you using? API 2.3.0?
If so, I suggest downgrading API version to API 2.2.0 just to make sure it is not related to API.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
13 Replies
- mikihiir
Helper III
Ok found something very strange, when debuggin identity object looks like this
DataView looks like this
I am confused :)
- v-viig
Community Champion
It's expected change that was made as a part of performance optimization for Custom Visuals API 2.x.x.
How are you generating a SelectionId?
I'm asking because the key property is not required to generate a SelectionId.
One possible break is with table and matrix mappings. You can have a look at this code sample to modify your code accordingly if you use table or matrix mappings.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- mikihiir
Helper III
Hi, thanks for replaying
This is how i create SelectionId ->
I am using categorical mapping