Add required attribute for Model Attributes
We need the ability to define that some attributes are required
whenever a specific Table Model is used in Meltano Analyze.
This is really important for reports on top of a single pre-aggregate table, where the data have no meaning without a specific attribute, e.g. the date or some other primary dimension (like for example gender, age group, etc).
This will not be that important once calculated and derived attributes are introduced, but until we fully support all types of derived/calculated metrics, we are forced to do some type of pre-aggregation and generate those report tables that we use in Meltano Analyze.
For those reports, always including the core dimensions is essential and our current approach of asking the user to only select a specific filter is pretty ugly:
But this will also be helpful either way, as there are Reports where without a specific attribute selected have no real meaning. What does it mean to check an Audience Stats by Device
report if the user does not at least pick a date segment and the device attribute?
But the later is more of an edge case. We really need this as a quick MVC to address the issue we have with Facebook Ads and Google Ads reports until we have a fully working solution for defining all the derived attributes in our models.
In contrast to the complicated implementation details of handling the various functions and computations included in a derived attribute, this approach just needs 2 steps:
-
Add a
required
parameter for columns defined in Meltano.m5o
tablesdevice_category { primary_key = true hidden = false required = true <============= label = Device Category description = Device Category type = string sql = "{{table}}.device_category" }
-
The Meltano Analyze goes through all the columns, pre-selects all the columns that
required = true
and grays them out (or something similar - so they can not be unselected)