Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
When a column being used as a relationship key contains the value "#", Power BI is unable to grant a One to Many or One to One relationship. Instead, the Create Relationship dialog box reads "The cardinality you selected isn't valid fo this relationship".
Specific context
When using the SAP Business Warehouse connector, two tables were imported. One, labeled Maintenance Items is the Fact table with various keys. The other, labeled ABC Indicator, is a lookup table with 4 rows.
Lookup table
The key for the last row is '#', something the SAP system uses instead of a blank value across all tables. Nonetheless, all keys are unique for the "One" part of the relationship.
Attempting to enforce a relationship after removing blanks/errors from both tables yields the following error:
error screen
By replacing both key columns ([Maintenance Items].[ABC Indicator Key] and [ABC Indicator].[Key]) '#' values with 'NA', we are now able to create a One to Many Relationship:
This bug can be frustrating for users who don't dig and run into a similar scenario.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.