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

Custom columns don't work after aggregation unless the user has native query permissions #42765

Open
zbodi74 opened this issue May 16, 2024 · 0 comments
Labels
Priority:P1 Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctness Querying/Processor .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. .Team/QueryProcessor :hammer_and_wrench: Type:Bug Product defects

Comments

@zbodi74
Copy link

zbodi74 commented May 16, 2024

Describe the bug

In questions based on native models, post aggregation custom columns no longer work, unless the user is given native query permissions.

To Reproduce

  1. Create a native model (select * from products), save it

Log in with a user that does not have native query permissions:
2. Create a GUI question, based on the model created in step 1
3. Add an aggregation(summarize: Count of Rows, by Category)
4. Add a custom column ([Count] + 1)
5.(!) Visualize, and see the error
image

Assigning native query permissions to the user makes the question runnabl.

Expected behavior

The question should work without native query permissions.

Logs

n/a

Information about your Metabase installation

1.49.10

Severity

P1 - affects a common function

Additional context

Reproduced it in 49.10 but I suspect the issue might have existed in earlier versions (49.8).

@zbodi74 zbodi74 added Type:Bug Product defects Priority:P1 Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctness Administration/Permissions Collection or Data permissions Querying/Nested Queries Questions based on other saved questions .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. labels May 16, 2024
@NevRA NevRA added Querying/Processor .Team/QueryProcessor :hammer_and_wrench: and removed Querying/Nested Queries Questions based on other saved questions Administration/Permissions Collection or Data permissions labels May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:P1 Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctness Querying/Processor .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. .Team/QueryProcessor :hammer_and_wrench: Type:Bug Product defects
Projects
None yet
Development

No branches or pull requests

2 participants