Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define Detail Rows if referenced measures use it #5

Open
marcosqlbi opened this issue Oct 11, 2017 · 6 comments
Open

Define Detail Rows if referenced measures use it #5

marcosqlbi opened this issue Oct 11, 2017 · 6 comments

Comments

@marcosqlbi
Copy link

Define Detail Rows if a measure depends on one or more other measures that have Detail Rows property defined.

@otykier
Copy link
Collaborator

otykier commented Oct 12, 2017

Hi Marco. Just to clarify. Assume I have the following measures and dependencies:

image

and Detail Rows have been defined at the top-most measure [Reseller Total Sales].

Should the rule then output all measures that depend on [Reseller Total Sales] recursively, or just the measures that reference it directly? I guess in the former case, the rule could potentially output many measures that would be in violation of the rule, and it would not always be clear why, where as in the latter case, the rule would have to be re-evaluated continuously while new Detail Rows expressions are added...

@marcosqlbi
Copy link
Author

Good point. I think that providing the warning at the first level is the right thing to do. However, we should figure out how to "disable" the warning for specific measures. I don't know whether we might use some annotation or some comment in the measure. For example, if it's ok that Total Sales doesn't provide the warning, I would like to mark Total Sales in some way, so that Reseller Current Quarter Sales still generates the warning (unless I disable that measure as well).

@otykier
Copy link
Collaborator

otykier commented Oct 12, 2017

This is already possible today. In the screenshot below, you can see that I've already ignored the rule for the [Total Sales] measure (shown in the Property Grid). As you can see, an annotation has been added to the measure, specifying the ID's of the rules that should be ignored:

image

One more question: Should the rule ignore measures residing on a table that has a Default Detail Rows Expression defined?

@marcosqlbi
Copy link
Author

Believe it or not, I missed the "Default Detail Rows Expression"!
Ok, I would do the following (but I'm very open to discuss it because I never spent too much time on this):

  • a measure A residing in a table X that has "Default Detail Rows Expression" is like a measure that has "Detail Rows Expression" defined locally on the measure (with one exception)
  • a measure B residing on table Y that depends on A should show the warning if "Detail Rows Expression" is not defined in B (regardless of the default in Y) --> however, for this case an "ignore rule on derived measures" applied to A could be useful.
  • a measure B residing on table X that depends on A should show the warning if a specific "Detail Rows Expression" is defined in A (regardless of the default in X) - this is the exception to the first rule (do you see my point for this case?)

Feedback is welcome - we are in unexplored territories here.

@otykier
Copy link
Collaborator

otykier commented Oct 12, 2017

I agree with your 3rd bullet, since we have to assume that, in general, if measure B depends on A, it must mean that B is a more "specialized" case of A. And so any "specialization" (in this case, Detail Row Expression different from the table default) that has been explicitly set on A, should also prompt us to consider doing something to B.

@marcosqlbi
Copy link
Author

This is also my feeling. Not sure how it can be implemented, but it is a "nice to have" feature,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants