Skip to content

[Bug]: The column name of is_nullable in table information_schema.columns is ambiguous. #11249

Closed

Description

@Ariznawlll

Is there an existing issue for the same bug?

  • I have checked the existing issues.

Environment

- Version or commit-id (e.g. v0.1.0 or 8b23a93): b0002bfac60998670ed15b164f51e44ada872697
- Hardware parameters:
- OS type:
- Others:

Actual Behavior

image

Expected Behavior

Is_nullable indicates whether the column is null,if the column is null, the fields should be YES, 
if the column is not null, the fields should be NO.

Steps to Reproduce

drop table if exists index04;
CREATE TABLE index04(a INTEGER PRIMARY KEY, b CHAR(10), c date, d decimal(7,2), INDEX(a, b), KEY(c));
insert into index04 values(1, 'ab', '1980-12-17', 800);
insert into index04 values(2, 'ac', '1981-02-20', 1600);
insert into index04 values(3, 'ad', '1981-02-22', 500);
select * from index04;
select table_name,COLUMN_NAME, data_type,is_nullable from information_schema.columns where table_name like 'index04' and COLUMN_NAME not like '__mo%';
No response

Additional information

No response

Activity

  1. added
    kind/bug
    severity/s1
    on Aug 16, 2023
  2. added this to the 1.0.0 milestone on Aug 16, 2023
  3. aronchanisme commented on Aug 16, 2023

    @aronchanisme
    Contributor

    Is_nullable indicates whether the column is null,if the column is null, the fields should be YES, 
if the column is not null, the fields should be NO.

    First, there might be some misunderstanding here. is_nullable function should be a function to tell whether a column is nullable or not, i.e. if it can be defined as a null value, but not as null itself because it could be null, and it could also not be null, if it's defined as null.

    Hence, as col1 is defined as not null, the output of is_nullable of this column should be NO but not YES. @YANGGMM Please help take a look.

  4. Ariznawlll commented on Aug 21, 2023

    @Ariznawlll
    CollaboratorAuthor

    Verifeid!

  5. matrix-meow commented on Aug 22, 2023

    @matrix-meow
    Contributor

    Hello @Ariznawlll. The bug issue in the BVT test code has not been removed,issues automatically open.

  6. modified the milestones: 1.0.0, 1.1.0 on Aug 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

kind/bugseverity/s1

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions