Forum Discussion

lwgpowerbiadmin's avatar
lwgpowerbiadmin
Frequent Visitor
4 years ago

Renaming multiple custom columns based on group id

Hi
I have to show table/matrix with more than 30 fields where 8 of them are custom fields.These custom fields names are customfield1,customfield2,customfield3,.....,customfield8. These fields are created by group admin according to their requirements so the number of custom fields they create will be different(max 8 fields) and the field names also. I am getting all the values of custom fields from the customfields1,2,...8 columns. Headers for custom fields should be dynamic based on the groupid
For that i have another table(CF Table) with following columns orderid(upto 8),groupid,userid,fieldname,fieldvalue.
This is an embedded report, so that the viewers will only get to see the data of one group which is their own.
The orderid 1 to 8 represents the customfield1 to customfield8 and buid is the groupid.

The values of the custom fields are available in both table but the header name is only available in CF Table. I want to rename the custom fields1 to 8 to their respective field name based on the groupid. 

Thank you.

2 Replies

    • lwgpowerbiadmin's avatar
      lwgpowerbiadmin
      Frequent Visitor

      Hi
      Thank you for replying.
      The given solution will not work as the customfields are already assigned in the matrix.
      The matrix visual will display error if the field name does not match. we cannot change the fields in the matrix every time.
      In the matrix all the customfields values are coming correctly but the column header won't change. I have another table for this dynamic header for the custom fields.
      The matrix have static fields,DAX measures and 8 dynamic custom field that can change according to group.
      Solution needed for changing custom fields header name according to the groupID in a matrix/table.

      Thanks