Skip to content

Conversation

@HappenLee
Copy link
Contributor

Proposed changes

BE crash when case:

CREATE TABLE `test` (
`name` varchar(64) NULL,
`age` int(11) NULL
) ENGINE=OLAP
DUPLICATE KEY(`name`)
COMMENT 'OLAP'
DISTRIBUTED BY HASH(`name`) BUCKETS 1
PROPERTIES (
"replication_allocation" = "tag.location.default: 1",
"in_memory" = "false",
"storage_format" = "V2",
"disable_auto_compaction" = "false"
);
insert into `test` values ("lemon",1),("tom",2);

select a.name regexp concat('^', a.name) from test a;

Problem summary

Describe your changes.

Checklist(Required)

  • Does it affect the original behavior
  • Has unit tests been added
  • Has document been added or modified
  • Does it need to update dependencies
  • Is this PR support rollback (If NO, please explain WHY)

Further comments

If this is a relatively large or complex change, kick off the discussion at dev@doris.apache.org by explaining why you chose the solution you did and what alternatives you considered, etc...

@HappenLee
Copy link
Contributor Author

run buildall

@github-actions github-actions bot added area/sql/function Issues or PRs related to the SQL functions area/vectorization kind/test labels Mar 20, 2023
@github-actions
Copy link
Contributor

clang-tidy review says "All clean, LGTM! 👍"

const auto& pattern_val = str_patterns->get_data_at(0);
RETURN_IF_ERROR(vector_const(*values, &pattern_val, vec_res, state->function,
&state->search_state));
for (int i = 0; i < input_rows_count; i++) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we forbid the pattern column is non-const?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I test mysql. mysql support the query non-const way

@HappenLee
Copy link
Contributor Author

run buildall

1 similar comment
@HappenLee
Copy link
Contributor Author

run buildall

@github-actions
Copy link
Contributor

clang-tidy review says "All clean, LGTM! 👍"

@hello-stephen
Copy link
Contributor

hello-stephen commented Mar 20, 2023

TeamCity pipeline, clickbench performance test result:
the sum of best hot time: 34.61 seconds
stream load tsv: 468 seconds loaded 74807831229 Bytes, about 152 MB/s
stream load json: 24 seconds loaded 2358488459 Bytes, about 93 MB/s
stream load orc: 76 seconds loaded 1101869774 Bytes, about 13 MB/s
stream load parquet: 33 seconds loaded 861443392 Bytes, about 24 MB/s
https://doris-community-test-1308700295.cos.ap-hongkong.myqcloud.com/tmp/20230320103434_clickbench_pr_117309.html

Copy link
Contributor

@yiguolei yiguolei left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@yiguolei yiguolei merged commit 7b93c17 into apache:master Mar 21, 2023
@yiguolei yiguolei added the usercase Important user case type label label Mar 22, 2023
morningman pushed a commit that referenced this pull request Mar 28, 2023
…17953)

CREATE TABLE `test` (
`name` varchar(64) NULL,
`age` int(11) NULL
) ENGINE=OLAP
DUPLICATE KEY(`name`)
COMMENT 'OLAP'
DISTRIBUTED BY HASH(`name`) BUCKETS 1
PROPERTIES (
"replication_allocation" = "tag.location.default: 1",
"in_memory" = "false",
"storage_format" = "V2",
"disable_auto_compaction" = "false"
);
insert into `test` values ("lemon",1),("tom",2);

select a.name regexp concat('^', a.name) from test a;
luwei16 pushed a commit to luwei16/incubator-doris that referenced this pull request Apr 7, 2023
…e#1586)

* [Bug][Fix] regexp function core dump DCHECK failed and error result (apache#17953)

CREATE TABLE `test` (
`name` varchar(64) NULL,
`age` int(11) NULL
) ENGINE=OLAP
DUPLICATE KEY(`name`)
COMMENT 'OLAP'
DISTRIBUTED BY HASH(`name`) BUCKETS 1
PROPERTIES (
"replication_allocation" = "tag.location.default: 1",
"in_memory" = "false",
"storage_format" = "V2",
"disable_auto_compaction" = "false"
);
insert into `test` values ("lemon",1),("tom",2);

select a.name regexp concat('^', a.name) from test a;

* [fix](like) fix wrong result of like pattern with backslash (apache#18351)

---------

Co-authored-by: HappenLee <happenlee@hotmail.com>
Co-authored-by: TengJianPing <18241664+jacktengg@users.noreply.github.com>
gnehil pushed a commit to gnehil/doris that referenced this pull request Apr 21, 2023
…pache#17953)

CREATE TABLE `test` (
`name` varchar(64) NULL,
`age` int(11) NULL
) ENGINE=OLAP
DUPLICATE KEY(`name`)
COMMENT 'OLAP'
DISTRIBUTED BY HASH(`name`) BUCKETS 1
PROPERTIES (
"replication_allocation" = "tag.location.default: 1",
"in_memory" = "false",
"storage_format" = "V2",
"disable_auto_compaction" = "false"
);
insert into `test` values ("lemon",1),("tom",2);

select a.name regexp concat('^', a.name) from test a;
mongo360 pushed a commit to mongo360/doris that referenced this pull request Jul 12, 2023
…pache#17953)

CREATE TABLE `test` (
`name` varchar(64) NULL,
`age` int(11) NULL
) ENGINE=OLAP
DUPLICATE KEY(`name`)
COMMENT 'OLAP'
DISTRIBUTED BY HASH(`name`) BUCKETS 1
PROPERTIES (
"replication_allocation" = "tag.location.default: 1",
"in_memory" = "false",
"storage_format" = "V2",
"disable_auto_compaction" = "false"
);
insert into `test` values ("lemon",1),("tom",2);

select a.name regexp concat('^', a.name) from test a;
swjtu-zhanglei pushed a commit to swjtu-zhanglei/incubator-doris that referenced this pull request Jul 25, 2023
…e#1586)

* [Bug][Fix] regexp function core dump DCHECK failed and error result (apache#17953)

CREATE TABLE `test` (
`name` varchar(64) NULL,
`age` int(11) NULL
) ENGINE=OLAP
DUPLICATE KEY(`name`)
COMMENT 'OLAP'
DISTRIBUTED BY HASH(`name`) BUCKETS 1
PROPERTIES (
"replication_allocation" = "tag.location.default: 1",
"in_memory" = "false",
"storage_format" = "V2",
"disable_auto_compaction" = "false"
);
insert into `test` values ("lemon",1),("tom",2);

select a.name regexp concat('^', a.name) from test a;

* [fix](like) fix wrong result of like pattern with backslash (apache#18351)

---------

Co-authored-by: HappenLee <happenlee@hotmail.com>
Co-authored-by: TengJianPing <18241664+jacktengg@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/sql/function Issues or PRs related to the SQL functions area/vectorization dev/1.2.4-merged kind/test usercase Important user case type label

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants