Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

interface conversion: expression.Expression is *expression.ScalarFunction, not *expression.Column #29401

Closed
ChenPeng2013 opened this issue Nov 3, 2021 · 3 comments · Fixed by #30002
Assignees
Labels
affects-5.0 This bug affects 5.0.x versions. affects-5.1 This bug affects 5.1.x versions. affects-5.2 This bug affects 5.2.x versions. affects-5.3 This bug affects 5.3.x versions. severity/major sig/planner SIG: Planner type/bug The issue is confirmed as a bug.

Comments

@ChenPeng2013
Copy link
Contributor

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

use test;
drop table if exists t;
CREATE TABLE `t` (
  `id` int(11) NOT NULL,
  `a` bigint(20) DEFAULT NULL,
  `b` char(20) DEFAULT NULL,
  `c` datetime DEFAULT NULL,
  `d` double DEFAULT NULL,
  `e` json DEFAULT NULL,
  `f` decimal(40,6) DEFAULT NULL,
  PRIMARY KEY (`id`) /*T![clustered_index] CLUSTERED */,
  KEY `a` (`a`),
  KEY `b` (`b`),
  KEY `c` (`c`),
  KEY `d` (`d`),
  KEY `f` (`f`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
explain select /*+ inl_hash_join(t1) */ * from t t1 join t t2 on t1.b=t2.e;

2. What did you expect to see? (Required)

3. What did you see instead (Required)

mysql> explain select /*+ inl_hash_join(t1) */ * from t t1 join t t2 on t1.b=t2.e;
ERROR 1105 (HY000): interface conversion: expression.Expression is *expression.ScalarFunction, not *expression.Column

4. What is your TiDB version? (Required)

Release Version: v5.3.0-alpha-1311-gb561dface
Edition: Community
Git Commit Hash: b561dface8b0b6408bc067189cf0bcbfd5c6d617
Git Branch: master
UTC Build Time: 2021-11-03 07:33:21
GoVersion: go1.17.2
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false
@ChenPeng2013 ChenPeng2013 added type/bug The issue is confirmed as a bug. sig/planner SIG: Planner severity/major labels Nov 3, 2021
@yudongusa
Copy link

@XuHuaiyu Could you please help to take a look if TiDB supports Char joins JSON type, and what would be the expected behavior and results?

@chrysan
Copy link
Contributor

chrysan commented Nov 22, 2021

/assign yisaer

@github-actions
Copy link

Please check whether the issue should be labeled with 'affects-x.y' or 'fixes-x.y.z', and then remove 'needs-more-info' label.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects-5.0 This bug affects 5.0.x versions. affects-5.1 This bug affects 5.1.x versions. affects-5.2 This bug affects 5.2.x versions. affects-5.3 This bug affects 5.3.x versions. severity/major sig/planner SIG: Planner type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants