Skip to content

Bug: Chinese/Unicode characters not supported as column aliases in bendsql #753

@wubx

Description

@wubx

Summary

In Databend's MySQL client, the following queries work correctly:

SELECT 'a' AS 中文;
SELECT 'a' 中文;

However, bendsql fails to handle Chinese (Unicode) characters used as unquoted column aliases.

Steps to Reproduce

-- Works in MySQL client connected to Databend
SELECT 'a' AS 中文;
SELECT 'a' 中文;

Try the same in bendsql — it fails to parse or execute correctly.

Expected Behavior

bendsql should support Unicode characters (including Chinese) as column aliases, consistent with Databend's MySQL client behavior.

Actual Behavior

bendsql does not handle Unicode/Chinese unquoted identifiers as column aliases.

Root Cause

Likely a lexer/parser issue in bendsql where identifier character validation does not include Unicode ranges beyond ASCII.

Environment

  • Databend: main branch
  • bendsql: (0.33.5-94d2cdc71cce4f72cd2bb788fc2686aca7fc9cbf)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions