[ 
https://issues.apache.org/jira/browse/HIVE-24893?focusedWorklogId=708841&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-708841
 ]

ASF GitHub Bot logged work on HIVE-24893:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 14/Jan/22 03:42
            Start Date: 14/Jan/22 03:42
    Worklog Time Spent: 10m 
      Work Description: wangyum commented on a change in pull request #2878:
URL: https://github.com/apache/hive/pull/2878#discussion_r784488086



##########
File path: service-rpc/if/TCLIService.thrift
##########
@@ -751,6 +751,52 @@ struct TGetTypeInfoResp {
   2: optional TOperationHandle operationHandle
 }
 
+// UploadData()
+//
+// UploadData data to table/path.
+struct TUploadDataReq {
+  // The session to execute the statement against
+  1: required TSessionHandle sessionHandle
+
+  // The table to be stored
+  2: optional string tableName
+
+  // The path to be stored
+  3: optional string path
+
+  // The data to be transferred
+  4: required binary values
+}
+
+struct TUploadDataResp {
+  1: required TStatus status
+  2: required TOperationHandle operationHandle
+}
+
+// DownloadData()
+//
+// Download data to JDBC client.
+struct TDownloadDataReq {
+  // The session to download data
+  1: required TSessionHandle sessionHandle
+
+  // The download table name
+  2: optional TPatternOrIdentifier tableName
+
+  // The download query
+  3: optional string query
+
+  // The download file format
+  4: optional string format

Review comment:
       For example, we want to download data as csv format, we don't need to 
care about the table format:
   ```scala
   spark.table("tableName").write.format("csv").option("dateFormat", 
"yyyy-MM-dd").save("/tmp/spark/download/sessionid/queryid")
   ```
   and then download data from `"/tmp/spark/download/sessionid/queryid"`.
   
   




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 708841)
    Time Spent: 1h  (was: 50m)

> Download data from Thriftserver through JDBC
> --------------------------------------------
>
>                 Key: HIVE-24893
>                 URL: https://issues.apache.org/jira/browse/HIVE-24893
>             Project: Hive
>          Issue Type: New Feature
>          Components: HiveServer2, JDBC
>    Affects Versions: 4.0.0
>            Reporter: Yuming Wang
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> It is very useful to support downloading large amounts of data (such as more 
> than 50GB) through JDBC.
> Snowflake has similar support :
> https://docs.snowflake.com/en/user-guide/jdbc-using.html#label-jdbc-download-from-stage-to-stream
> https://github.com/snowflakedb/snowflake-jdbc/blob/95a7d8a03316093430dc3960df6635643208b6fd/src/main/java/net/snowflake/client/jdbc/SnowflakeConnectionV1.java#L886



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to