Re: [Discussion] Make SubTreeHintPropagateShuttle hint that match the search layer can be configured

2023-08-14 Thread Julian Hyde
I haven’t had time to review your code, but I want to point out that when you want things to propagate up the tree, the metadata system is often the best fit. Hints are tricky. They originate as comments in SQL. Those comments are then applied to one RelNode when the SQL is translated. Now we

Re: [Question] Working with defaults in calcite.

2023-08-14 Thread Julian Hyde
If you way there are no execution tests, I wouldn’t be surprised. DDL was historically deemed out of scope, and what we didn’t implement, we couldn’t test. But now we have the ’server’ component, and there are tests such as table.iq [1]. Can you add some tests? Julian [1]

Re: Understanding the RelMdColumnUniqueness private constructor

2023-08-14 Thread Julian Hyde
I checked a few other RelMdXxx classes, and. they have private constructors too. Which makes sense, because you don’t extend metadata providers by subclassing. You just define your own provider and add it to the chain. RelMdColumnUniqueness has public static final RelMetadataProvider SOURCE

Re: TimeString

2023-08-11 Thread Julian Hyde
ince it > precludes using high precision time values. > > Mihai > > On Fri, Aug 11, 2023 at 2:50 PM Julian Hyde wrote: > >> In compilers it is a best practice to represent literals using exact, >> unbounded precision values. In Calcite we use BigDecimal for numb

Re: TimeString

2023-08-11 Thread Julian Hyde
In compilers it is a best practice to represent literals using exact, unbounded precision values. In Calcite we use BigDecimal for numbers and TimeString (TimestampString, DateString) for date and time literals. At runtime there are different considerations. We need a representation that is space

[jira] [Created] (CALCITE-5916) In RelBuilder, add sample() method (equivalent to SQL TABLESAMPLE clause)

2023-08-10 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5916: Summary: In RelBuilder, add sample() method (equivalent to SQL TABLESAMPLE clause) Key: CALCITE-5916 URL: https://issues.apache.org/jira/browse/CALCITE-5916 Project

Re: Why is Filter's condition required to be flat?

2023-08-09 Thread Julian Hyde
Flattened expressions - so that AND never contains a child that is AND, and OR never contains a child that is OR - is a canonized form that seems to have more advantages than disadvantages. It's never larger than the original (unlike CNF and DNF), frequently smaller than the original, doesn't take

[jira] [Created] (CALCITE-5914) Cache compiled regular expressions in SQL function runtime

2023-08-09 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5914: Summary: Cache compiled regular expressions in SQL function runtime Key: CALCITE-5914 URL: https://issues.apache.org/jira/browse/CALCITE-5914 Project: Calcite

Re: [Question] What is meaning of tablesample substitute('medium')?

2023-08-08 Thread Julian Hyde
It substitutes a named data set for a table. We added it to support SQLstream, a streaming SQL system. When developing streaming queries, it was sometimes convenient to substitute a table for a stream, because the table had predictable results and didn’t need another process inserting the

Re: [Discussion] Can we forbidden SEARCH operator when use other execution engine?

2023-08-08 Thread Julian Hyde
implement an equivalent transformation within Kylin, or even exploring the > possibility of creating a similar implementation in other execution engines > like Spark. > > On Sat, Aug 5, 2023 at 2:57 AM Julian Hyde wrote: > >> I agree that it should be solved ‘by config’ but

Re: Extending SqlColumnDeclaration

2023-08-07 Thread Julian Hyde
Intentional. See https://github.com/apache/calcite/blob/98f3048fb1407e2878162ffc80388d4f9dd094b2/core/src/main/java/org/apache/calcite/sql/ddl/package-info.java#L25: * If you are writing a project that requires DDL it is likely that your * DDL syntax is different than ours. We recommend that

Re: [DISCUSS] Increase the default maximum precision and scale of the number type

2023-08-07 Thread Julian Hyde
Calcite works best when it is able to execute the SQL that it accepts. If we were to allow say DECIMAL(200, 5) we would need to be able to generate Java code that can handle values of that type. The current maximum, DECIMAL(19), can be handled by 64-bit signed integers (Java long). > On Aug

Re: DECIMAL(2, 3) meaning

2023-08-06 Thread Julian Hyde
As I commented in https://issues.apache.org/jira/browse/CALCITE-5901, I don’t think it’s a bug to support behavior beyond what the standard requires. Which Calcite does, intentionally. Julian > On Aug 6, 2023, at 08:35, stanilovsky evgeny > wrote: > > Ok, seems like a bug. > Feel free to

Re: [Discussion] Can we forbidden SEARCH operator when use other execution engine?

2023-08-04 Thread Julian Hyde
I agree that it should be solved ‘by config’ but not by global config. The mere fact that you are talking to Spark (i.e. using the JDBC adapter with the Spark dialect) should be sufficient right? Put another way. Calcite’s internal representation for expressions is what it is. The fact that

Re: AggregateProjectPullUpConstantsRule not working with the Volcano Planner

2023-08-03 Thread Julian Hyde
The constraints on a RelSubset should be the union of the constraints of all of the RelNodes in that subset. (I haven’t tested it, or read the code. But if it doesn’t do that, you’re probably seeing a bug, or you haven’r configured your metadata providers correctly.) > On Aug 3, 2023, at 9:33

Re: [Question] CAST possibility cases

2023-08-02 Thread Julian Hyde
I think there’s at least one jira case discussing Boolean cast. Can you locate it? > On Aug 2, 2023, at 5:46 AM, stanilovsky evgeny > wrote: > > hello all ! > According to sql standard, chapter: 6.22 > We can found, for example, that casting from BOOLEAN is deprecated into Exact > Numeric,

Re: Creating user-defined functions dynamically

2023-08-01 Thread Julian Hyde
When you prepare a statement you can provide an instance of SqlOperatorTable that contains any functions you desire. (The ‘fun’ JDBC connect string parameter is just one means to construct such a table. It happens to be particularly convenient for people who wish to create a connection by

Re: PR CALCITE-5681 Review Request

2023-08-01 Thread Julian Hyde
I took a very quick look. This looks very well structured (with nice abstractions Principal, Grant and Revoke commands, and I like how you have made the parser extensible). This is definitely worth reviewing and getting to complation. * Terminology. You have made Grant and Revoke sub-classes

Re: Empty array literal

2023-08-01 Thread Julian Hyde
I don’t know - maybe it’s not in the sql standard? Can’t deduce a type? Any existing issues logged? Julian > On Jul 31, 2023, at 6:35 PM, mbu...@gmail.com wrote: > > Hello, > > > > It looks to me like the Calcite grammar does not accept empty array literals > "ARRAY[]". > > This sounds

Re: Community over Code (ApacheCon) East Asia

2023-07-31 Thread Julian Hyde
te and Flink). > > Hope to see you guys there! > > [1] https://apachecon.com/acasia2023/sessions/keynote-1234.html > > Julian Hyde 于2023年6月12日周一 05:15写道: > >> Community over Code (ApacheCon) East Asia is happening in August, and >> the call for papers closes in

Re: [Help Needed] Dissecting CTE out of Calcite LogicPlan

2023-07-26 Thread Julian Hyde
Your images did not come through (ASF mail server strips them from all emails) but I’ll try my best to answer. As you note, we added the Spool operator to model the case where the RelNode tree is a DAG (one node has more than one consumer). But other than that, relational algebra doesn’t have

Re: [VOTE] Release Apache Calcite 1.35.0 (release candidate 3)

2023-07-23 Thread Julian Hyde
+1 Downloaded; checked signatures; checked LICENSE, NOTICE; built and ran tests on Linux using Gradle 7.4.2 and OpenJDK 18.0.2; ran rat. Notes: * Please add your signature to KEYS. I had to import from xiong.asc manually. * The parser generator reports a choice conflict on the "TRUNCATE"

Re: Window functions frame_exclusion

2023-07-16 Thread Julian Hyde
It would be good to have this as a feature. Are you proposing to fully implement the feature (I.e. add to parser, validator, and Enumerable convention, so that we can execute such queries) or just add it to the parser? I think our users might be confused or frustrated if the parser supports the

Re: [VOTE] Release Apache Calcite 1.35.0 (release candidate 0)

2023-07-16 Thread Julian Hyde
I don’t think the short links are an improvement to the vote email. The release notes could be improved. I think CONVERT counts as a new feature. Puffin and PairList do not (they’re utility classes). There are so many new functions this time, how about adding a new section, and sorting them

Re: Developing a new SqlDialect

2023-07-11 Thread Julian Hyde
I see those problems too. A major problem is that when you start a new dialect, there are no tests. And that’s because our dialect test does not execute queries, only compares generated SQL (and those SQL fragments need to be entered by hand). There’s a good reason that our dialect test does

Fwd: Data Engineering track for Community Over Code NA is calling for presentations

2023-07-07 Thread Julian Hyde
Calcite community members, As the message below says, the CFP for Community Over Code North America closes in a few days. It would be great if there were talks about Calcite. Consider submitting to the Data Engineering track (see below), the Big Data track and the Geospatial track. Also

Re: Force push to calcite main

2023-07-07 Thread Julian Hyde
o force push, I would rebase to incorporate their changes > if possible, and make sure I notify whoever pushed. > > -- > Michael Mior > mm...@apache.org > > > On Fri, Jul 7, 2023 at 2:19 PM Julian Hyde wrote: > >>> I prefer keeping force push in pla

Re: Force push to calcite main

2023-07-07 Thread Julian Hyde
> I prefer keeping force push in place +1. I use force push about a dozen times a year and hopefully no one notices. It helps the commit history clean. I know that force pushes can confuse CI systems and make things confusing to other users, so I try to be judicious. I trust other committers

Re: Java Doc about RexProgramBuilderBase

2023-07-07 Thread Julian Hyde
People refactoring code should remember that their IDE can move and rename fields but is not so good at changing documentation. (Maybe in a couple of years, with advances in generative AI?!) And when documentation and code don’t line up, people don’t trust either. (I’m as guilty of this as

Re: [ANNOUNCE] New committer: Dan Zou

2023-07-05 Thread Julian Hyde
Welcome, Dan! And thank you for your contributions so far. > On Jul 4, 2023, at 7:12 PM, Jiajun Xie wrote: > > Congratulations, Dan! > > On Tue, 4 Jul 2023 at 19:48, Runkang He wrote: > >> Congratulations, Dan! >> >> Best, >> Runkang He >> >> Jacky Lau 于2023年7月4日周二 18:56写道: >> >>>

Re: [ANNOUNCE] New committer: TJ Banghart

2023-07-05 Thread Julian Hyde
Welcome, TJ! Thank you for your work on both Calcite and Avatica. As you’re my colleague, I know what you do, but please feel free to introduce yourself to the community. Julian > On Jul 4, 2023, at 7:11 PM, Jiajun Xie wrote: > > Congratulations, TJ! > > On Wed, 5 Jul 2023 at 01:03, Tanner

Re: Draft: board report for 2023 Q2

2023-07-05 Thread Julian Hyde
+-+-+ >>>> | 2023| 4 | 17 | >>>> | 2023| 5 | 21 | >>>> | 2023| 6

Re: [DISCUSS] Towards Calcite 1.35.0

2023-07-05 Thread Julian Hyde
I’ve been working on a few lint improvements in https://github.com/julianhyde/calcite/tree/-lint. I’ll merge those in (rules and fixes) before the release. > On Jul 5, 2023, at 11:26 AM, Julian Hyde wrote: > > I don’t think CALCITE-5701 (named_struct) is ready. (I had

Re: [DISCUSS] Towards Calcite 1.35.0

2023-07-05 Thread Julian Hyde
eviewed CALCITE-5708 and CALCITE-5727, which are >>> two I felt I understood well enough to review. >>> >>> On 2023/06/28 19:36:16 Julian Hyde wrote: >>> > I have taken care of 1, 2, 3, 4. >>> > >>> > Tanner, can you do 5. >>> &

Re: Optimal way to organize Joins in Calcite

2023-07-03 Thread Julian Hyde
The reason that there are two strategies is because of large joins. If your query joins 10 tables, the number of possible join orders is large (bounded by 10 factorial I believe) and therefore would overwhelm the Volcano planner, which must construct each possibility. Therefore we have a

Re: [DISCUSS] Towards Calcite 1.35.0

2023-06-28 Thread Julian Hyde
re are some issue statuses that need to be resolved: >> >> >> 1. https://issues.apache.org/jira/browse/CALCITE-5764(The PR has >> merge.But issue is IN PROGRESS). (Assigine Julian Hyde) >> 2. https://issues.apache.org/jira/browse/CALCITE-5706(The PR has &g

Re: [ANNOUNCE] New committer: Jacky Lau

2023-06-28 Thread Julian Hyde
Welcome, Jacky! Thanks for your excellent PRs. Julian > On Jun 28, 2023, at 8:51 AM, Michael Mior wrote: > > Congratulations and welcome Jacky! > -- > Michael Mior > mm...@apache.org > > > On Wed, Jun 28, 2023 at 6:47 AM Stamatis Zampetakis > wrote: > >> Apache Calcite's Project

Re: [ANNOUNCE] New committer: Zhe Hu

2023-06-28 Thread Julian Hyde
Thanks for your contributions, and welcome to the team! Julian > On Jun 28, 2023, at 8:52 AM, Michael Mior wrote: > > Congratulations and welcome Zhe Hu! > -- > Michael Mior > mm...@apache.org > > > On Wed, Jun 28, 2023 at 7:04 AM Stamatis Zampetakis > wrote: > >> Apache Calcite's Project

[jira] [Created] (CALCITE-5802) In RelBuilder add method aggregateExtended, to allow aggregating complex expressions such as "1 + SUM(x + 2)"

2023-06-26 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5802: Summary: In RelBuilder add method aggregateExtended, to allow aggregating complex expressions such as "1 + SUM(x + 2)" Key: CALCITE-5802 URL: https://issues.apach

Re: [DISCUSS] Towards Calcite 1.35.0

2023-06-23 Thread Julian Hyde
nd >>> https://issues.apache.org/jira/browse/CALCITE-5477 to be fixed in 1.35.0. >>> There are PRs for both of these fixes. We are working on addressing review >>> comments and just need a few days of time. >>> >>> On Thu, Jun 1, 2023 at 3:32 AM Julian Hyde

Re: VARIANT and JSON data types

2023-06-21 Thread Julian Hyde
https://issues.apache.org/jira/browse/CALCITE-4918 > On Jun 21, 2023, at 6:41 PM, wrote: > > Hello, > > > > I have a question about Calcite and fancier data types. > > It looks like Calcite JSON operations are really implemented by treating > JSON as a string. I expect that this is

Re: Support Graph Query In Calcite

2023-06-21 Thread Julian Hyde
I’ll reiterate what Stamatis said: log Jira tickets. Most of us know only vaguely what a graph query is. A well-written Jira case (describing the problem, with a couple of good SQL examples) will educate the people who would be reviewing the PR. > On Jun 20, 2023, at 10:42 PM, pzwpzw >

[jira] [Created] (CALCITE-5790) Query with "*" but no FROM clause should be invalid

2023-06-20 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5790: Summary: Query with "*" but no FROM clause should be invalid Key: CALCITE-5790 URL: https://issues.apache.org/jira/browse/CALCITE-5790 Projec

[jira] [Created] (CALCITE-5788) Order of metadata handler methods is inconsistent in different java versions

2023-06-19 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5788: Summary: Order of metadata handler methods is inconsistent in different java versions Key: CALCITE-5788 URL: https://issues.apache.org/jira/browse/CALCITE-5788

OSS-Fuzz

2023-06-16 Thread Julian Hyde
Someone from Google logged a case offering to add Calcite to the OSS-Fuzz program. (I work for Google but was not aware that we were being considered.) https://issues.apache.org/jira/browse/CALCITE-5781 How do people feel about participating in this program? I think that it could improve our

Re: PR 3258 Review Request

2023-06-16 Thread Julian Hyde
Nice work. (The hardest thing we do, as software engineers, is to make our work easy for others to understand. The fact that several databases have functions called CONCAT, with subtly different behaviors, made this task particularly challenging. You produced a solution that makes the

Re: [ANNOUNCE] New committer: Oliver Lee

2023-06-13 Thread Julian Hyde
Thanks for your contributions, Oliver! And welcome! On Tue, Jun 13, 2023 at 4:31 AM Zhe Hu wrote: > > Congrats Oliver! > Replied Message > | From | xiong duan | > | Date | 06/13/2023 19:17 | > | To | dev | > | Subject | Re: [ANNOUNCE] New committer: Oliver Lee | > Congratulations

Community over Code (ApacheCon) East Asia

2023-06-11 Thread Julian Hyde
Community over Code (ApacheCon) East Asia is happening in August, and the call for papers closes in LESS THAN A WEEK [1]. I'm proud of how many Calcite community members we have in China and East Asia, and I appreciate the constant stream of excellent and innovative contributions. If you are one

Re: PR 3250 (PairList, LintTest, Puffin, TestUnsafe)

2023-06-08 Thread Julian Hyde
me.) Julian On Wed, Jun 7, 2023 at 2:34 PM Julian Hyde wrote: > > Can I please get a review for PR 3250? It has several commits that are > loosely connected. > > CALCITE-5762 should be reviewed from a security perspective (because > it deals with unsafe methods such

PR 3250 (PairList, LintTest, Puffin, TestUnsafe)

2023-06-07 Thread Julian Hyde
Can I please get a review for PR 3250? It has several commits that are loosely connected. CALCITE-5762 should be reviewed from a security perspective (because it deals with unsafe methods such as ProcessBuilder). CALCITE-5764 adds a fun class called Puffin that brings the scripting capabilities

[jira] [Created] (CALCITE-5765) Add LintTest, to apply custom lint rules to source code

2023-06-07 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5765: Summary: Add LintTest, to apply custom lint rules to source code Key: CALCITE-5765 URL: https://issues.apache.org/jira/browse/CALCITE-5765 Project: Calcite

[jira] [Created] (CALCITE-5764) Puffin, an Awk for Java

2023-06-07 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5764: Summary: Puffin, an Awk for Java Key: CALCITE-5764 URL: https://issues.apache.org/jira/browse/CALCITE-5764 Project: Calcite Issue Type: Bug

[jira] [Created] (CALCITE-5763) Discontinue support for Guava < 20.0

2023-06-07 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5763: Summary: Discontinue support for Guava < 20.0 Key: CALCITE-5763 URL: https://issues.apache.org/jira/browse/CALCITE-5763 Project: Calcite Issue Type:

[jira] [Created] (CALCITE-5762) Create class TestUnsafe, that contains unsafe methods used by tests

2023-06-07 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5762: Summary: Create class TestUnsafe, that contains unsafe methods used by tests Key: CALCITE-5762 URL: https://issues.apache.org/jira/browse/CALCITE-5762 Project

Re: Implementing EXPLODE operator

2023-06-03 Thread Julian Hyde
he effort would even make sense. Was > EXPLODE not included by design? Would you recommend against adding it? > > Soumyadeep. > > > >> On Sat, 3 Jun 2023 at 9:51 PM, Julian Hyde wrote: >> >> I can’t tell whether you are intending to contribute EXPLODE or

Re: Implementing EXPLODE operator

2023-06-03 Thread Julian Hyde
I can’t tell whether you are intending to contribute EXPLODE or do it on a private branch. You don’t make a case for what EXPLODE could do, so I presume the latter. UNNEST is a unique function. Its implementation is (unfortunately but necessarily) spread over many files. Copy-pasting it to

Re: Algebraic optimizations rule

2023-06-03 Thread Julian Hyde
Be careful when applying algebraic optimizations to computer numbers. For example, a + (b - c) = (a + b) - c doesn’t hold if a, b and c are floating point numbers, a and “b - c” are small, and b and c are large. “a + (b - c)” will experience less underflow and will deliver a more accurate

[jira] [Created] (CALCITE-5746) Support JDK 19

2023-06-02 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5746: Summary: Support JDK 19 Key: CALCITE-5746 URL: https://issues.apache.org/jira/browse/CALCITE-5746 Project: Calcite Issue Type: Bug Reporter

Re: [DISCUSS] Towards Calcite 1.35.0

2023-05-31 Thread Julian Hyde
There's one Jira case we should fix: https://issues.apache.org/jira/browse/CALCITE-5737 (support JDK 19 and 20). Can someone take that on? Julian On 2023/05/30 08:33:23 xiong duan wrote: > Yes. I can release 1.35.0 when the PR is handled. > > Julian Hyde 于2023年5月30日周二 05:46写道: &

[jira] [Created] (CALCITE-5737) Support JDK 19, JDK 20

2023-05-31 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5737: Summary: Support JDK 19, JDK 20 Key: CALCITE-5737 URL: https://issues.apache.org/jira/browse/CALCITE-5737 Project: Calcite Issue Type: Bug

Re: [DISCUSS] Towards Calcite 1.35.0

2023-05-29 Thread Julian Hyde
ext version. What do you think? > > According to [4], the following release managers would be: > - 1.35.0 Duan Xiong > - 1.36.0 Benchao Li > - 1.37.0 Sergey Nuyanzin > - 1.38.0 Julian Hyde > > @Duan Xiong, are you still available for being the release manager for > 1.35.0? > &g

Re: [ANNOUNCE] New committer: Tanner Clary

2023-05-28 Thread Julian Hyde
Welcome to the community, Tanner! You've earned it. On Sun, May 28, 2023 at 5:11 AM Jacky Lau wrote: > > Congratulations, Tanner! > > Best regards, > Jacky > > Jiajun Xie 于2023年5月27日周六 11:28写道: > > > Congratulations and welcome, Tanner! > > > > On Sat, 27 May 2023 at 02:46, Sergey Nuyanzin

[jira] [Created] (CALCITE-5726) Canonize use of Hamcrest matchers in test code

2023-05-26 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5726: Summary: Canonize use of Hamcrest matchers in test code Key: CALCITE-5726 URL: https://issues.apache.org/jira/browse/CALCITE-5726 Project: Calcite Issue

Re: Add new functions in existing dialects

2023-05-25 Thread Julian Hyde
You could do something that substitutes RexCalls or SqlCalls of unsupported function calls with calls to supported functions. But be sure to remember that the semantics of functions does not depend on the target dialect. Function semantics are always in terms of Calcite’s dialect. This matters

Re: Question | Referencing column alias in WHERE clause

2023-05-22 Thread Julian Hyde
It does not currently. See https://issues.apache.org/jira/browse/CALCITE-5248. > On May 22, 2023, at 4:12 AM, Zineeddine ZIDANE wrote: > > Does calcite support referencing column aliases in WHERE clause? I know SQL > doesn't allow this but it is supported out of the box in databases such as >

Re: Translate join predicates into filters

2023-05-18 Thread Julian Hyde
I expect that your table works if you put the filter in the WHERE clause, e.g. SELECT * FROM Books AS b WHERE b.id IN (1, 10, 27) and it does so using FilterTableScanRule (which matches a Filter on top of a Scan of a FilterableTable). But you need a new planner rule that

LITERAL_AGG

2023-05-17 Thread Julian Hyde
Can someone please review https://github.com/apache/calcite/pull/3209. It has fixes for https://issues.apache.org/jira/browse/CALCITE-4334 (LITERAL_AGG) and https://issues.apache.org/jira/browse/CALCITE-5697 (RelBuilder.convert). I would especially like feedback on the strategy of avoiding a

[jira] [Created] (CALCITE-5706) Add class PairList

2023-05-16 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5706: Summary: Add class PairList Key: CALCITE-5706 URL: https://issues.apache.org/jira/browse/CALCITE-5706 Project: Calcite Issue Type: Bug Reporter

Re: structs

2023-05-15 Thread Julian Hyde
I added some comments to the Jira case. Thanks for finding PR 2573 (for https://issues.apache.org/jira/browse/CALCITE-4842). I think that case needs to be fixed first. That PR looks almost ready. Julian > On May 15, 2023, at 11:51 AM, Guillaume Masse > wrote: > > Hi All, > > I created a

[jira] [Created] (CALCITE-5697) RelBuilder.convert does not match nullability if top of stack is a Project

2023-05-10 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5697: Summary: RelBuilder.convert does not match nullability if top of stack is a Project Key: CALCITE-5697 URL: https://issues.apache.org/jira/browse/CALCITE-5697 Project

[jira] [Created] (CALCITE-5692) Add AT operator, for context-sensitive expressions

2023-05-06 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5692: Summary: Add AT operator, for context-sensitive expressions Key: CALCITE-5692 URL: https://issues.apache.org/jira/browse/CALCITE-5692 Project: Calcite Issue

Re: Authentication and authorizations in Calcite

2023-05-01 Thread Julian Hyde
che.org/jira/browse/CALCITE-2194 > https://issues.apache.org/jira/browse/CALCITE-5292 > > Best, > Stamatis > > > > On Sat, Apr 29, 2023 at 2:11 AM Julian Hyde wrote: >> >> I think Calcite should stay out of the authentication business. The >&g

[jira] [Created] (CALCITE-5681) Support authorization via GRANT and REVOKE DDL commands

2023-05-01 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5681: Summary: Support authorization via GRANT and REVOKE DDL commands Key: CALCITE-5681 URL: https://issues.apache.org/jira/browse/CALCITE-5681 Project: Calcite

Re: [DISCUSS] Running Sql Logic Tests for Calcite

2023-04-29 Thread Julian Hyde
:41 Julian Hyde wrote: > I agree with Stamatis that this has a similar “shape” to Quidem. I’d be happy > to host the project under github.com/hydromatic. (If the maven group is > net.hydromatic I can publish artifacts to Maven Central and Calcite could > depend on those artifacts.) &g

Re: Employ bloom filters in joins

2023-04-28 Thread Julian Hyde
It would be great to have such a rule. People who don’t want it can disable it; and people who enable it can use a cost function. Some systems that use Bloom filters (and other probabilistic filters) don’t execute the query twice but use a side-channel to send the Bloom filter from one scan to

Re: Authentication and authorizations in Calcite

2023-04-28 Thread Julian Hyde
I think Calcite should stay out of the authentication business. The container (not Calcite) should authenticate users and convert them to security principals that Calcite knows about. (Avatica does authentication [1] but it just delegates to a provider.) Regarding authorization. I support

Re: Rewrite rule to convert self-joins into scans

2023-04-19 Thread Julian Hyde
to express an SPJ query but I think the general idea of > grouping joins together seems to be a promising direction for writing > new rules. > > Best, > Stamatis > > On Sun, Apr 16, 2023 at 2:27 AM Julian Hyde wrote: >> >> Ian Bertolacci recently logged >> ht

Re: [DISCUSS] Running Sql Logic Tests for Calcite

2023-04-17 Thread Julian Hyde
I agree with Stamatis that this has a similar “shape” to Quidem. I’d be happy to host the project under github.com/hydromatic. (If the maven group is net.hydromatic I can publish artifacts to Maven Central and Calcite could depend on those artifacts.) Regarding the frequency of testing. If we

Rewrite rule to convert self-joins into scans

2023-04-15 Thread Julian Hyde
Ian Bertolacci recently logged https://issues.apache.org/jira/browse/CALCITE-5631, to convert select (select numarrayagg(C5633_203) from T893 where C5633_586 = T895.id), (select numarrayagg(C5633_170) from T893 where C5633_586 = T895.id) from T895 into select agg.agg1,

[jira] [Created] (CALCITE-5645) Correlated scalar sub-query returns incorrect results when the correlating variable is NULL

2023-04-13 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5645: Summary: Correlated scalar sub-query returns incorrect results when the correlating variable is NULL Key: CALCITE-5645 URL: https://issues.apache.org/jira/browse/CALCITE-5645

Re: How to utilize parser hooks such as SqlInsertKeywords

2023-04-10 Thread Julian Hyde
To research this, I would use 'git annotate' and identify the commits and Jira cases that added those particular hooks. On Tue, Apr 4, 2023 at 9:22 AM Jonathan Sternberg wrote: > > Hi, > > We're utilizing Calcite's parser and need to customize it for a certain > dialect. In the past, we've just

[DISCUSS] Sharing the load of reviewing PRs

2023-04-10 Thread Julian Hyde
I don't enjoy reviewing and merging PRs. And every time I do, I feel like a sucker, because there are over a few dozen committers who are enjoying the project and not doing the work. (There is a small group of committers who regularly review and merge PRs. I don't know how they feel about the

Re: calcite lsp server

2023-04-07 Thread Julian Hyde
I wrote SqlAdvisor [1] with the goal of enabling auto completion in SQL editors, but I never took the next step of wrapping it as a service. Julian [1] https://calcite.apache.org/javadocAggregate/org/apache/calcite/sql/advise/SqlAdvisor.html > On Apr 6, 2023, at 1:30 PM, Guillaume Masse >

Re: Using calcite to parse untrusted SQL queries and add implicit filters

2023-04-02 Thread Julian Hyde
+1 what Askar said Also you could give users access to views. A particular user might have a view with “WHERE tenant = 100” so if they ask for any any other tenant is they would get no results. It’s also possible to use Calcite to check grants (table and column access) and fail a query if

[jira] [Created] (CALCITE-5629) In TimestampString, allow negative years and years with more than 4 digits

2023-04-01 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5629: Summary: In TimestampString, allow negative years and years with more than 4 digits Key: CALCITE-5629 URL: https://issues.apache.org/jira/browse/CALCITE-5629 Project

Re: Rules to squash redundant join sides?

2023-03-30 Thread Julian Hyde
I agree with Stamatis that this would be a useful feature. The first step would be log a jira case with a clear description of the problem. Can you describe exactly what you mean by ‘mergeable’, ‘redundant' and ’squash’? I can’t follow your example, Ian. Can you find a simpler example, or

Fwd: CI requiring approval for external contributors

2023-03-28 Thread Julian Hyde
(Forwarding from the Druid list for discussion.) Julian Begin forwarded message: > From: Gian Merlino > Date: March 28, 2023 at 1:24:42 AM CDT > To: d...@druid.apache.org > Subject: CI requiring approval for external contributors > Reply-To: d...@druid.apache.org > > Recently, ASF GitHub

Re: Help with implementation of parsing typed array from string

2023-03-27 Thread Julian Hyde
Are you familiar with the work I did in https://issues.apache.org/jira/browse/CALCITE-5424 to defer the creation of literals? Previously when a literal is a type followed by a string, such as DATE ‘1969-07-21’, the string was parsed in the parser; now we defer parsing the string until

Re: [DISCUSS] Calcite Release Managers

2023-03-26 Thread Julian Hyde
t; >>> As I've said in another ML thread[1], I will volunteer to do one. >>> >>> [1] https://lists.apache.org/thread/dcf6o3mdzflh7brsklgoy7fd1njy8jjz >>> >>> Stamatis Zampetakis 于2023年3月21日周二 17:01写道: >>> >>>> Hi everyone, >&g

[jira] [Created] (CALCITE-5601) Set 'timestamp' and 'timezone' in Quidem test scripts, and have datetime functions observe them

2023-03-21 Thread Julian Hyde (Jira)
Julian Hyde created CALCITE-5601: Summary: Set 'timestamp' and 'timezone' in Quidem test scripts, and have datetime functions observe them Key: CALCITE-5601 URL: https://issues.apache.org/jira/browse/CALCITE-5601

Re: register a custom udf

2023-03-20 Thread Julian Hyde
What language is this? > On Mar 20, 2023, at 9:01 AM, Guillaume Masse > wrote: > > Hi All, > > How can we register a custom udf? I found some solutions on Stackoverflow > but they are out of date ( > https://stackoverflow.com/questions/44147819/adding-a-user-defined-function-to-calcite > ) >

Re: Proper way to convert names when going between conventions

2023-03-17 Thread Julian Hyde
The casing of names seems to be part of the schema factory rather than the convention. Schema factory is the ‘front door’ of an adapter, allows you to make a connection, and read tables. So the casing of those table and column names seems to fit there. Convention is used by the planner, which

Re: Requesting PR Reviews

2023-03-17 Thread Julian Hyde
Yes, non-committers can review. We welcome it - and in fact reviewing is a good way to earn merit and become a committer. Of course the PR can only be committed by a committer. But reviewing - and the back-and-forth after a review, including reviewing revisions to the PR - is a major part of the

Re: Proposal for basic client side load balancing in Avatica

2023-03-16 Thread Julian Hyde
It makes sense. It might not meet the needs of everyone (e.g. I could imagine that occasionally a URL would naturally contain a comma), but if so, they can contribute enhancements. > On Mar 13, 2023, at 9:12 PM, Vaibhav Joshi > wrote: > > Greetings, > > We have created a ticket CALCITE-5581

Parameterized types

2023-03-12 Thread Julian Hyde
Should Calcite support parameterized types, also known as type constructors? If so, what should be the syntax? (We’re not considering user defined parameterized types at this point, only built in type constructors such as MAP, but we are choosing a syntax.) See discussion in

Re: [VOTE] Release Apache Calcite 1.34.0 (release candidate 0)

2023-03-10 Thread Julian Hyde
+1 (binding) Steps: * Downloaded; * checked signatures/hashes; * checked LICENSE, NOTICE, README, README.md; * compiled and ran tests on Ubuntu Linux, OpenJDK 18 using 'gradle build'; * also compiled and ran tests with -Pguava.version=16.0.1, the lowest supported Guava version; * checked

Re: [QUESTION]: Bug Fix Release

2023-03-09 Thread Julian Hyde
ontent/groups/snapshots/org/apache/calcite/calcite-core/1.34.0-SNAPSHOT/ > >>> On Sun, Mar 5, 2023 at 7:16 PM Charles Givre wrote: > >>> > >>>> Julian, > >>>> Now that Drill is on main Calcite instead of the fork, I'll commit that > >>>

Re: Future of the Spatial Type Extension

2023-03-07 Thread Julian Hyde
> On Mar 6, 2023, at 3:37 PM, Bertil Chapuis wrote: > > Thank you for your answers and for the pointers. > >> PS Regarding which specification we choose to implement. The four principles >> you outline sound good to me. It’s always better to follow the standard. If >> leading

Re: A new logo for avatica?

2023-03-07 Thread Julian Hyde
; -- > Michael Mior > mm...@apache.org > > > On Mon, Mar 6, 2023 at 8:50 PM Julian Hyde wrote: > > > A logo would be great. > > > > I don't think the logo should be a variation of Calcite's logo. > > Although Avatica is developed by the Calcite comm

Re: A new logo for avatica?

2023-03-06 Thread Julian Hyde
A logo would be great. I don't think the logo should be a variation of Calcite's logo. Although Avatica is developed by the Calcite community, I don't want people to see it as a standalone component. By the way, the name Avatica is inspired by the scientific name of the Barn spider, Araneus

<    1   2   3   4   5   6   7   8   9   10   >