Forum Discussion
Dynamic Table in Power BI
- Anonymous4 years ago
Hi lfholland,
I think you need to create a parameter that stored the rule to remark records, then you can add a calculated column to your fact table and lookup at the above parameter table rules, and compare with the current row value to setting corresponding groups.
SWITCH function (DAX) - DAX | Microsoft Docs
From SQL to DAX: String Comparison - SQLBI
Regards,
Xiaoxin Sheng
Please provide sanitized sample data that fully covers your issue. If you paste the data into a table in your post or use one of the file services it will be easier to work with. Avoid posting screenshots of your source data if possible.
Please show the expected outcome based on the sample data you provided. Screenshots of the expected outcome are ok.
https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523
The screen shot I posted is my expected outcome; however, I can provide a little more variety as to what I need. Below is a sample of what I need.
I'm wondering as another solution if there is a type of "wildmatch" that can be used in an if statement? For example if the first character of the account code is 1 or 2, Header_1 is "ASSESTS". If the account code begins with 100, Header_2 is "cash", etc.
| ACCOUNT_CODE | Header_1 | Header_2 | Header_4 | Header_5 |
| 1002330 | ASSETS: | Cash | Total Assets | Balance Sheet |
| 1002400 | ASSETS: | Cash | Total Assets | Balance Sheet |
| 1002401 | ASSETS: | Cash | Total Assets | Balance Sheet |
| 1002402 | ASSETS: | Cash | Total Assets | Balance Sheet |
| 1002403 | ASSETS: | Cash | Total Assets | Balance Sheet |
| 1002404 | ASSETS: | Cash | Total Assets | Balance Sheet |
| 1300 | ASSETS: | Total AR | Total Assets | Balance Sheet |
| 1300100 | ASSETS: | Total AR | Total Assets | Balance Sheet |
| 1326 | ASSETS: | Total AR | Total Assets | Balance Sheet |
- lbendlin4 years agoSuper User
Please provide sanitized sample data that fully covers your issue.
- Anonymous4 years agoNot applicable
Hi lfholland,
I think you need to create a parameter that stored the rule to remark records, then you can add a calculated column to your fact table and lookup at the above parameter table rules, and compare with the current row value to setting corresponding groups.
SWITCH function (DAX) - DAX | Microsoft Docs
From SQL to DAX: String Comparison - SQLBI
Regards,
Xiaoxin Sheng
- lfholland4 years agoAdvocate I
I think this will work. I'll test it out and let you know. Thank you!!!