[jira] [Created] (CALCITE-6391) Apply mapping to RelCompositeTrait does not apply it to wrapped traits

2024-04-29 Thread James Duong (Jira)
James Duong created CALCITE-6391: Summary: Apply mapping to RelCompositeTrait does not apply it to wrapped traits Key: CALCITE-6391 URL: https://issues.apache.org/jira/browse/CALCITE-6391 Project

Re: [DISCUSS] Towards Calcite 1.37.0

2024-03-18 Thread James Duong
I’ll help take a look at some of the open Avatica and Calcite PRs. From: Mihai Budiu Date: Monday, March 18, 2024 at 9:48 AM To: dev@calcite.apache.org Subject: Re: [DISCUSS] Towards Calcite 1.37.0 This would be great, I am fixing two very basic bugs. Was busy with some other stuff, so I didn't

Re: Supporting a function with different capabilities depending on database

2024-03-12 Thread James Duong
cepts. Julian > On Mar 8, 2024, at 1:40 PM, James Duong > wrote: > > Incidentally, in the PR that added the FloorCeil approach, it was suggested > based on the SqlStdOperatorTable.like(boolean, boolean) function. > > However I don’t see this method referenced anywhere in eithe

Re: Supporting a function with different capabilities depending on database

2024-03-08 Thread James Duong
see it referenced in the PR it was introduced in so it appears to be superfluous? I must be missing something – is this invoked with reflection somewhere? Thanks From: James Duong Date: Friday, March 8, 2024 at 12:12 PM To: dev@calcite.apache.org Subject: Supporting a function with different

Supporting a function with different capabilities depending on database

2024-03-08 Thread James Duong
Hi Calcite dev, I’m working on adding support for more PostgreSQL functions based on PostgreSQL 14 – See https://issues.apache.org/jira/browse/CALCITE-6308. Some functions such as LOG have different semantics depending on which database is used: * In PostgreSQL, LOG with one argument is

[jira] [Created] (CALCITE-6314) Support PostgreSQL RANDOM

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6314: Summary: Support PostgreSQL RANDOM Key: CALCITE-6314 URL: https://issues.apache.org/jira/browse/CALCITE-6314 Project: Calcite Issue Type: Sub-task

[jira] [Created] (CALCITE-6315) Support PostgreSQL TO_CHAR, TO_DATE, TO_TIMESTAMP

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6315: Summary: Support PostgreSQL TO_CHAR, TO_DATE, TO_TIMESTAMP Key: CALCITE-6315 URL: https://issues.apache.org/jira/browse/CALCITE-6315 Project: Calcite Issue

[jira] [Created] (CALCITE-6312) Support PostgreSQL LOG

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6312: Summary: Support PostgreSQL LOG Key: CALCITE-6312 URL: https://issues.apache.org/jira/browse/CALCITE-6312 Project: Calcite Issue Type: Sub-task

[jira] [Created] (CALCITE-6311) Support PostgreSQL DATE_PART

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6311: Summary: Support PostgreSQL DATE_PART Key: CALCITE-6311 URL: https://issues.apache.org/jira/browse/CALCITE-6311 Project: Calcite Issue Type: Sub-task

[jira] [Created] (CALCITE-6313) Support PostgreSQL POW

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6313: Summary: Support PostgreSQL POW Key: CALCITE-6313 URL: https://issues.apache.org/jira/browse/CALCITE-6313 Project: Calcite Issue Type: Sub-task

[jira] [Created] (CALCITE-6310) Support PostgreSQL REGEXP_REPLACE

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6310: Summary: Support PostgreSQL REGEXP_REPLACE Key: CALCITE-6310 URL: https://issues.apache.org/jira/browse/CALCITE-6310 Project: Calcite Issue Type: Sub-task

[jira] [Created] (CALCITE-6309) Support PostgreSQL REGEXP_LIKE

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6309: Summary: Support PostgreSQL REGEXP_LIKE Key: CALCITE-6309 URL: https://issues.apache.org/jira/browse/CALCITE-6309 Project: Calcite Issue Type: Sub-task

[jira] [Created] (CALCITE-6308) Add PostgreSQL functions up to PostgreSQL v14

2024-03-07 Thread James Duong (Jira)
James Duong created CALCITE-6308: Summary: Add PostgreSQL functions up to PostgreSQL v14 Key: CALCITE-6308 URL: https://issues.apache.org/jira/browse/CALCITE-6308 Project: Calcite Issue Type

[jira] [Created] (CALCITE-2614) Converting datetime_plus to timestampadd should be done recursively

2018-10-05 Thread James Duong (JIRA)
James Duong created CALCITE-2614: Summary: Converting datetime_plus to timestampadd should be done recursively Key: CALCITE-2614 URL: https://issues.apache.org/jira/browse/CALCITE-2614 Project

[jira] [Created] (CALCITE-2603) Error double literal with exponential when unparsing with RelToSqlConverter

2018-09-30 Thread James Duong (JIRA)
James Duong created CALCITE-2603: Summary: Error double literal with exponential when unparsing with RelToSqlConverter Key: CALCITE-2603 URL: https://issues.apache.org/jira/browse/CALCITE-2603

Unparsing only a SqlNode sub-tree

2018-07-25 Thread James Duong
Hi, During the process of unparsing a SqlNode tree, is there a way to unparse a subtree to a String then cache its value? I was thinking I could spawn another SqlWriter from the SqlWriter object supplied to unparse(), then pull the SQL string fragment from it. But the SqlWriter isn't cloneable,

[jira] [Created] (CALCITE-2399) Allow SqlImplementor classes to be extended

2018-07-03 Thread James Duong (JIRA)
James Duong created CALCITE-2399: Summary: Allow SqlImplementor classes to be extended Key: CALCITE-2399 URL: https://issues.apache.org/jira/browse/CALCITE-2399 Project: Calcite Issue Type

[jira] [Created] (CALCITE-2398) SqlSelect does not use SqlDialect when unparsing

2018-07-03 Thread James Duong (JIRA)
James Duong created CALCITE-2398: Summary: SqlSelect does not use SqlDialect when unparsing Key: CALCITE-2398 URL: https://issues.apache.org/jira/browse/CALCITE-2398 Project: Calcite Issue

[jira] [Created] (CALCITE-2397) Column Index not getting set on correlationIds

2018-07-03 Thread James Duong (JIRA)
James Duong created CALCITE-2397: Summary: Column Index not getting set on correlationIds Key: CALCITE-2397 URL: https://issues.apache.org/jira/browse/CALCITE-2397 Project: Calcite Issue

[jira] [Created] (CALCITE-2396) TIMESTAMPADD and DATETIME_PLUS should allow NULL intervals

2018-07-03 Thread James Duong (JIRA)
James Duong created CALCITE-2396: Summary: TIMESTAMPADD and DATETIME_PLUS should allow NULL intervals Key: CALCITE-2396 URL: https://issues.apache.org/jira/browse/CALCITE-2396 Project: Calcite

Review request - Calcite-2359 (inconsistent behavior casting intervals to integers)

2018-06-26 Thread James Duong
Hi, Can I get someone to review CALCITE-2359: https://issues.apache.org/jira/browse/CALCITE-2359 The PR is here: https://github.com/apache/calcite/pull/730

Datetime_plus and timestampadd return types

2018-06-18 Thread James Duong
Hi, According to the ODBC spec ( https://docs.microsoft.com/en-us/sql/odbc/reference/appendixes/time-date-and-interval-functions?view=sql-server-2017), when the return type inference for timestampadd should be: 1. If the datetime type is a date, and the time unit is a time, promote to timestamp.

[jira] [Created] (CALCITE-2359) Inconsistent behavior when casting interval literals to integer

2018-06-12 Thread James Duong (JIRA)
James Duong created CALCITE-2359: Summary: Inconsistent behavior when casting interval literals to integer Key: CALCITE-2359 URL: https://issues.apache.org/jira/browse/CALCITE-2359 Project: Calcite

Re: Datetime_Plus and TimestampAdd operators

2018-05-30 Thread James Duong
Datetime_plus only such as Oracle. On Wed, May 30, 2018 at 7:32 AM, James Duong wrote: > Thanks Michael. > > Here is a link to a Google Doc: > https://docs.google.com/document/d/1j0wa0pZ2senQhAoy_ > 3W_Ev2vHqIhm3ob19BGy4nBJkI/edit?usp=sharing > > On Wed, May 30, 2018 at

Re: Datetime_Plus and TimestampAdd operators

2018-05-30 Thread James Duong
creating > a Google Doc with the contents. > > -- > Michael Mior > mm...@uwaterloo.ca > > > Le mer. 30 mai 2018 à 04:23, James Duong a écrit : > > > I've recorded my thoughts on this in the attached document > > > > A few notes: > > - TimestampAd

Re: Datetime_Plus and TimestampAdd operators

2018-05-30 Thread James Duong
. On Mon, May 28, 2018 at 6:52 PM, Julian Hyde wrote: > I think we should use the datetime_plus operator. It is standard, and > sufficiently general. Its second argument needs to be an interval > value, not necessarily an interval literal. > > On Mon, May 28, 2018 at 2:35 PM, Jam

Datetime_Plus and TimestampAdd operators

2018-05-28 Thread James Duong
There are essentially two ways to add an interval to a datetime vaue in Calcite Call the timestampadd() function: select {fn timestampadd(year, 1, hire_date)}... Use datetime_plus interval arithmetic: select hire_date + interval '1' year Note that timestampadd's second argument does not need

[jira] [Created] (CALCITE-2299) TIMESTAMPADD(SQL_TSI_FRAC_SECOND) should be nanoseconds not microseconds

2018-05-03 Thread James Duong (JIRA)
James Duong created CALCITE-2299: Summary: TIMESTAMPADD(SQL_TSI_FRAC_SECOND) should be nanoseconds not microseconds Key: CALCITE-2299 URL: https://issues.apache.org/jira/browse/CALCITE-2299 Project