calcite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrei Sereda <and...@sereda.cc>
Subject Re: Bindable Baz.bind(DataContext) issue
Date Thu, 09 Aug 2018 13:28:56 GMT
Dylan,

The query translation is happening in PredicateAnalyzer
<https://github.com/apache/calcite/blob/master/elasticsearch/src/main/java/org/apache/calcite/adapter/elasticsearch/PredicateAnalyzer.java#L326>
(called inside ElasticsearchFilter).
Any reason why you want match query instead of term
<https://www.elastic.co/guide/en/elasticsearch/guide/current/term-vs-full-text.html>
?

On Thu, Aug 9, 2018 at 6:06 AM Vladimir Sitnikov <
sitnikov.vladimir@gmail.com> wrote:

> Dylan>What can I do to see the source code of the method bindable.bind() to
> change the way of serializing the SQL query into JSON query ?
>
> You might find adding -Dcalcite.debug=true entertaining (see
> https://calcite.apache.org/docs/howto.html#running-tests )
>
> Baz code is generated on the fly, so there's no sources in git for it,
> however if you supply `-Dcalcite.debug=true`, then the sources will be
> printed to the console.
>
> However, it looks like you want to inspect
>
> https://github.com/apache/calcite/blob/6344afc4770b6bb5bafc27c7d3709ab69b52633a/elasticsearch/src/main/java/org/apache/calcite/adapter/elasticsearch/ElasticsearchFilter.java#L55
> or something like that since translation of rel expressions to JSON query
> is placed there.
>
>
> PS. We might want to add an option to actually save the generated sources
> in the file system, so IDE might be able to set breakpoints and
> step-by-step execute the generated on the fly sources as well.
>
> Vladimir
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message