The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I am trying to return a certain default image if a neighborhood is selected in the bar chart filter, but I don't have a corresponding picture for the city that the neighborhood is in. I have a key that corresponds cities and all the neighborhoods that are in them ("FSA to City Key"):
Nothing I try will return the default "Canada" image for a neighborhood with no corresponding city picture. My code is:
(The concatenating function works fine, it's just the first line after "IF" that I'm having trouble with.)
I have tried IF(NOT(HASONEVALUE), IF(ISEMPTY(VALUES)), and IF(COUNTROWS)=0 and nothing works. I don't know what else to try. Is the "many to many" relationship a problem here? It's many to many because in the Images Table, I need multiple rows concatenated together to handle the base 64, and in the FSA to City key, the cities are listed multiple times because there are several neighborhoods per city.
I don't see how the many-to-many could be a problem because when I filter my '2021 FSA API Data' table with an FSA with no corresponding city image, there should literally be no city rows to show in my Image Table.
Or could it have something to do with the .jpg? FSA matches with the city.jpg merged in FSA to City Key, which which then matches with the city.jpg in the Image Table.
Where is the issue?
This is the error message I get when I click on a neighborhood where I don't have a corresponding city: