Giter VIP home page Giter VIP logo

Comments (3)

blathers-crl avatar blathers-crl commented on May 27, 2024

Hello, I am Blathers. I am here to help you get the issue triaged.

I have CC'd a few people who may be able to assist you:

  • @cockroachdb/sql-queries (found keywords: optimizer,vectorized)

If we have not gotten back to your issue within a few business days, you can try the following:

  • Join our community slack channel and ask on #cockroachdb.
  • Try find someone from here if you know they worked closely on the area and CC them.

🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is dev-inf.

from cockroach.

michae2 avatar michae2 commented on May 27, 2024

Hi @rootjalex, thanks for filing an issue.

The optimizer might consider rewriting these expressions, i.e. greatest(a, b) < c -> a < c AND b < c and least(a, b) < c -> a < c OR b < c. I'm new to cockroachdb, so not sure how much the optimizer already tries to rewrite conditionals, but if I do this greatest rewrite manually, I get the index behavior that I expect (i.e. x < 15000 AND y < 15000 produces a filter(index join(scan))).

Yes, I think to optimize this we'd need to add another comparison normalization rule, similar to these.

from cockroach.

mgartner avatar mgartner commented on May 27, 2024

Unfortunately, the transformation suggested is not valid in the presence of NULL arguments to greatest/least. See my comment here: #119979 (review)

I think there are likely some tweaks we can make to make it valid, though there will likely be limitations that may limit its usefulness in addressing the original goal of leading to constrained index scans.

from cockroach.

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.