spectacles icon indicating copy to clipboard operation
spectacles copied to clipboard

Add SQL validator support for measures

Open DylanBaker opened this issue 2 years ago • 3 comments
trafficstars

Change description

Adding support for measures in the SQL validator

Type of change

  • [ ] Bug fix (fixes an issue)
  • [x] New feature (adds functionality)

Related issues

Closes #368

Checklists

Security

  • [x] Security impact of change has been considered
  • [x] Code follows security best practices and guidelines

Code review

  • [x] Pull request has a descriptive title and context useful to a reviewer

DylanBaker avatar Mar 01 '23 16:03 DylanBaker

Thank you!

jschintz-windriver avatar Mar 02 '23 21:03 jschintz-windriver

A few high-level questions:

1. Aside from allowing measures to flow through into the LookML tree, is there anything else special happening to test them?

2. I'm not seeing any tests specifically for measures, just the refactored existing tests.

3. Should we expect performance to be impacted by including aggregates in the Explore-level queries?
  1. No, all we are changing is adding them when building the LookML tree. Everything else is unchanged except for renaming and the excluding measures functionality.

  2. A number of the integration test results were changed to account for the new measures coming in. I also added new tests for excluding measures that have the original numbers. Happy to add more if desired.

  3. I don't believe so. The only warehouse I'd be concerned by is Snowflake, given the weirdness of their query planner, but we would need to test. I'd recommend having people opt in to testing in the app (by having exclude measures set to true by default).

DylanBaker avatar Mar 21 '23 12:03 DylanBaker

As far as measure-specific tests go, we may want to make sure all measure types are supported, since we don't have all of them defined on our eye-exam project.

joshtemple avatar Apr 10 '23 18:04 joshtemple