Uh oh!
There was an error while loading. Please reload this page.
[feature](hive)support create hive table for text format - #41860
Merged
Conversation
doris-robot
commented
Oct 15, 2024
Thank you for your contribution to Apache Doris. Since 2024-03-18, the Document has been moved to doris-website. |
wuwenchi
commented
Oct 15, 2024
ContributorAuthor
run buildall |
| @VariableMgr.VarAttr(name = HIVE_TEXT_COMPRESSION, needForward = true) | ||
| private String hiveTextCompression = "uncompressed"; | ||
| private String hiveTextCompression = "plain"; |
Contributor
There was a problem hiding this comment.
change default value? what will happen when upgrade from older version?
Contributor
There was a problem hiding this comment.
I did the compatible process. If user set "uncompressed", it will change to plain
| return HiveMetaStoreClientHelper.firstPresentOrDefault(DEFAULT_NULL_FORMAT, nullFormat); | ||
| } | ||
| public static void updateProperties(Table table, Map<String, String> properties) { |
Contributor
There was a problem hiding this comment.
Add comment to explain this method
| case FORMAT_CSV_PLAIN: | ||
| compressType = ConnectContext.get().getSessionVariable().hiveTextCompression(); | ||
| compressType = targetTable.getRemoteTable().getParameters().get("text.compression"); | ||
| if (compressType == null) { |
Contributor
There was a problem hiding this comment.
Suggested change
| if (compressType == null) { | |
| if (Strings.isNullOrEmpty(compressType)) { |
morningmanforce-pushed
the
fix-hive-text
branch
from
October 17, 2024 05:03
6c03485 to
0a38900Comparemorningman
commented
Oct 17, 2024
Contributor
run buildall |
Contributor
PR approved by anyone and no changes requested. |
morningman added a commit
to morningman/doris
that referenced
this pull request
Oct 21, 2024
We can create hive table for text format with `'file_format'='text'`, and set related properties: ```sql create table tb ( id int, `name` string ) PROPERTIES ( 'file_format'='text', 'compression'='gzip', 'field.delim'='\t', 'line.delim'='\n', 'collection.delim'=';', 'mapkey.delim'=':', 'serialization.null.format'='\\N', 'escape.delim'='\\' ); ``` --------- Co-authored-by: morningman <morningman@163.com>
morningman added a commit
that referenced
this pull request
Oct 21, 2024
morningman added a commit
to morningman/doris
that referenced
this pull request
Oct 21, 2024
We can create hive table for text format with `'file_format'='text'`, and set related properties: ```sql create table tb ( id int, `name` string ) PROPERTIES ( 'file_format'='text', 'compression'='gzip', 'field.delim'='\t', 'line.delim'='\n', 'collection.delim'=';', 'mapkey.delim'=':', 'serialization.null.format'='\\N', 'escape.delim'='\\' ); ``` --------- Co-authored-by: morningman <morningman@163.com>
morningman added a commit
that referenced
this pull request
Oct 21, 2024
Closed
HappenLee pushed a commit
to HappenLee/incubator-doris
that referenced
this pull request
Apr 24, 2026
We can create hive table for text format with `'file_format'='text'`, and set related properties: ```sql create table tb ( id int, `name` string ) PROPERTIES ( 'file_format'='text', 'compression'='gzip', 'field.delim'='\t', 'line.delim'='\n', 'collection.delim'=';', 'mapkey.delim'=':', 'serialization.null.format'='\\N', 'escape.delim'='\\' ); ``` --------- Co-authored-by: morningman <morningman@163.com>
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.
We can create hive table for text format with
'file_format'='text', and set related properties: