Coder Social home page Coder Social logo

Comments (3)

bshepherdson avatar bshepherdson commented on June 18, 2024

You're exactly right about what's going on here. In legacy MBQL, aggregation references are done by an index into the aggregations list.

MLv2 (new library and MBQL format) use UUIDs to reference aggregations, avoiding this problem. But legacy is still the source of truth in the appdb and on the wire, so we're not free of this bug yet.

from metabase.

meldiner avatar meldiner commented on June 18, 2024

@bshepherdson, thanks for confirming. Do you expect updating metabase version to resolve this?

from metabase.

bshepherdson avatar bshepherdson commented on June 18, 2024

I regret to say "not yet". I just checked this with the 0.49 RC and while the behavior has changed slightly (the expression is less broken after making the edit), this has not been fixed.

This is one of the diverse symptoms of a fundamental issue #36185 with how Metabase handles similar but not identical columns. There are lots of other ways to trip over this bug, such as joining the same table twice, or naming a custom column the same as a column from an earlier stage.

When the first aggregation max is deleted, the two surviving ones are renamed from max_2 and max_3 to max and max_2. The expression in the second stage of the query has a reference like [:field "max_2"], which is still valid. We don't currently connect the dots that the artist column formerly known as max_2 is now known as max.

So this won't be fixed in 49 or 50, but fixing that issue is one of my long-term goals. Much of the groundwork for it has landed over the past six months or so, but we're not ready to eliminate this issue yet.

from metabase.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.