Hey All, WDF question. How does a WDF handle null...
# gooddata-cloud
s
Hey All, WDF question. How does a WDF handle null values? Scenario: • I have a list of items that are global • For some accounts they have additional items in that list If I have a WDF that is on an account id, then I have null values in the global items, would those be included or excluded from being included in all accounts
j
In general it is recommended to include all possible values in dimension dataset otherwise some values which will appear in data will be not available in filters. In case there is a NULL value in the fact dataset it is recommended to replace it by some special value (e.g. “N/A”) and include it to the dimension dataset, so that it can be filtered out as well.
j
Currently NULL values are excluded - we generate something like
WHERE wdf_column IN ('values1'. 'value2', ...)
. Anyway, the concept described by @Joseph Heun is strongly recommended - we don't want to JOIN tables by NULL values, it would negatively affect the performance of JOIN operations.
e
Hi! Pulling up this old thread as I'm running into what seems like the same thing. We have a data set that contains a combination of customer-specific (contains an ID that's part of the WDF) and platform-managed data (currently is null for that ID). Trying to figure out the best path forward. It would be easy enough to update our dimensional dataset to include some special value (e.g., N/A) instead of null. But then... trying to figure out if it makes more sense to: 1. Update WDF such that for each workspace, it will include both the items specific to the ID that's on the WDF AND the N/A items OR 2. Update our dimensional table to "fan out" and essentially duplicate each of the platform managed data records for each customer that has used it. Curious how others have ended up handling this / what's recommended!