[
https://issues.apache.org/jira/browse/CALCITE-6736?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Mihai Budiu updated CALCITE-6736:
---------------------------------
Description:
The validator rejects this comparison (taken from SqlValidatorTest):
{code}
expr("^x'a4'=1^")
.fails("(?s).*Cannot apply '=' to arguments of type '<BINARY.1.> =
<INTEGER>'.*");
{code}
But happily accepts this comparison:
{code}
expr("array[x'e4'] <> array[1]")
.ok();
{code}
The validator should reject comparisons between arrays whose element types are
not comparable.
was:
The validator rejects this comparison (taken from SqlValidatorTest):
{code{
expr("^x'a4'=1^")
.fails("(?s).*Cannot apply '=' to arguments of type '<BINARY.1.> =
<INTEGER>'.*");
{code}
But happily accepts this comparison:
{code}
expr("array[x'e4'] <> array[1]")
.ok();
{code}
The validator should reject comparisons between arrays whose element types are
not comparable.
> Validator accepts comparisons between arrays without regard to element types
> ----------------------------------------------------------------------------
>
> Key: CALCITE-6736
> URL: https://issues.apache.org/jira/browse/CALCITE-6736
> Project: Calcite
> Issue Type: Bug
> Components: core
> Affects Versions: 1.38.0
> Reporter: Mihai Budiu
> Assignee: Mihai Budiu
> Priority: Minor
>
> The validator rejects this comparison (taken from SqlValidatorTest):
> {code}
> expr("^x'a4'=1^")
> .fails("(?s).*Cannot apply '=' to arguments of type '<BINARY.1.> =
> <INTEGER>'.*");
> {code}
> But happily accepts this comparison:
> {code}
> expr("array[x'e4'] <> array[1]")
> .ok();
> {code}
> The validator should reject comparisons between arrays whose element types
> are not comparable.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)