-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Map SQL Server tinyint to Trino SMALLINT
In the original implementation, we mapped SQL Server tinyint to Trino TINYINT, but there is a difference in the range they supported: - Trino TINYINT supports a range of [-128, 127] - SQL Server tinyint supports a range of [0, 255] So we can't read or write values in the range [128, 255], so we map SQL Server tinyint to Trino SMALLINT in this commit. Although we are now extending the range of SQL Server tinyint in Trino, we don't have to worry about Trino writing values that are not in the range [0, 255] to SQL Server, because SQL Server already guarantees this for us and this behavior is verified by the `BaseSqlServerTypeMapping#testUnsupportedTinyint` test.
- Loading branch information
1 parent
b67d9bb
commit 4b20ba1
Showing
6 changed files
with
41 additions
and
15 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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