Uh oh!
There was an error while loading. Please reload this page.
[fix](variables) change column type of @@autocommit to BIGINT - #33282
Merged
Conversation
doris-robot
commented
Apr 6, 2024
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
morningman
commented
Apr 6, 2024
ContributorAuthor
run buildall |
yiguolei
reviewed
Apr 7, 2024
| @@ -3206,14 +3205,14 @@ public void readFromJson(String json) throws IOException { | |||
Contributor
There was a problem hiding this comment.
我觉得这么写太迷惑了,不如直接在加一个新的annotation,比如叫做converter="convertToFromBoolean"
然后在session variable 里定义一下。 这样就相当于只对auto commit 这一个变量做一下convert。
否则类似3208行,这是大面上都在做convert,未来很难扩展。
morningman
commented
Apr 7, 2024
ContributorAuthor
run buildall |
Contributor
PR approved by at least one committer and no changes requested. |
doris-robot
commented
Apr 7, 2024
TPC-H: Total hot run time: 38799 ms |
Contributor
PR approved by anyone and no changes requested. |
yiguolei
commented
Apr 7, 2024
Contributor
run buildall |
doris-robot
commented
Apr 7, 2024
TPC-H: Total hot run time: 38662 ms |
doris-robot
commented
Apr 7, 2024
TPC-DS: Total hot run time: 180699 ms |
doris-robot
commented
Apr 7, 2024
ClickBench: Total hot run time: 29.89 s |
doris-robot
commented
Apr 7, 2024
Load test result on machine: 'aliyun_ecs.c7a.8xlarge_32C64G' |
wuwenchi
approved these changes
Apr 7, 2024
zddr
approved these changes
Apr 7, 2024
yiguolei pushed a commit
that referenced
this pull request
Apr 7, 2024
Some of mysql connector (eg, dotnet MySQL.Data) rely on variable's column type to make connection. eg, `select @@autocommit` should with column type `BIGINT`, not `BIT`, otherwise it will throw error like: ``` System.FormatException: The input string 'True' was not in a correct format. at System.Number.ThrowFormatException[TChar](ReadOnlySpan`1 value) at System.Convert.ToInt32(String value) at MySql.Data.MySqlClient.Driver.LoadCharacterSetsAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.ConfigureAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() ``` In this PR, I add a new field of `VarAttr`: `convertBoolToLongMethod`, if set, it will convert boolean to long. And set it for `autocommit`
Closed
seawinde pushed a commit
to seawinde/doris
that referenced
this pull request
Apr 10, 2024
…#33282) Some of mysql connector (eg, dotnet MySQL.Data) rely on variable's column type to make connection. eg, `select @@autocommit` should with column type `BIGINT`, not `BIT`, otherwise it will throw error like: ``` System.FormatException: The input string 'True' was not in a correct format. at System.Number.ThrowFormatException[TChar](ReadOnlySpan`1 value) at System.Convert.ToInt32(String value) at MySql.Data.MySqlClient.Driver.LoadCharacterSetsAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.ConfigureAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() ``` In this PR, I add a new field of `VarAttr`: `convertBoolToLongMethod`, if set, it will convert boolean to long. And set it for `autocommit`
This was referenced Apr 19, 2024
morningman added a commit
to morningman/doris
that referenced
this pull request
Jun 20, 2024
…#33282) Some of mysql connector (eg, dotnet MySQL.Data) rely on variable's column type to make connection. eg, `select @@autocommit` should with column type `BIGINT`, not `BIT`, otherwise it will throw error like: ``` System.FormatException: The input string 'True' was not in a correct format. at System.Number.ThrowFormatException[TChar](ReadOnlySpan`1 value) at System.Convert.ToInt32(String value) at MySql.Data.MySqlClient.Driver.LoadCharacterSetsAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.ConfigureAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() ``` In this PR, I add a new field of `VarAttr`: `convertBoolToLongMethod`, if set, it will convert boolean to long. And set it for `autocommit`
morningman added a commit
that referenced
this pull request
Jun 20, 2024
Closed
mongo360 pushed a commit
to mongo360/doris
that referenced
this pull request
Aug 16, 2024
HappenLee pushed a commit
to HappenLee/incubator-doris
that referenced
this pull request
Apr 24, 2026
…#33282) Some of mysql connector (eg, dotnet MySQL.Data) rely on variable's column type to make connection. eg, `select @@autocommit` should with column type `BIGINT`, not `BIT`, otherwise it will throw error like: ``` System.FormatException: The input string 'True' was not in a correct format. at System.Number.ThrowFormatException[TChar](ReadOnlySpan`1 value) at System.Convert.ToInt32(String value) at MySql.Data.MySqlClient.Driver.LoadCharacterSetsAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.Driver.ConfigureAsync(MySqlConnection connection, Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.OpenAsync(Boolean execAsync, CancellationToken cancellationToken) at MySql.Data.MySqlClient.MySqlConnection.Open() ``` In this PR, I add a new field of `VarAttr`: `convertBoolToLongMethod`, if set, it will convert boolean to long. And set it for `autocommit`
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Proposed changes
Some of mysql connector (eg, dotnet MySQL.Data) rely on variable's column type to make connection.
eg,
select @@autocommitshould with column typeBIGINT, notBIT, otherwise it will throw error like:In this PR, I add a new field of
VarAttr:convertBoolToLongMethod, if set, it will convert boolean to long.And set it for
autocommitFurther 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...