You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/data-factory/connector-presto.md
+100-2Lines changed: 100 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ author: jianleishen
6
6
ms.subservice: data-movement
7
7
ms.custom: synapse
8
8
ms.topic: conceptual
9
-
ms.date: 10/20/2023
9
+
ms.date: 03/25/2023
10
10
ms.author: jianleishen
11
11
---
12
12
# Copy data from Presto using Azure Data Factory or Synapse Analytics
@@ -62,7 +62,58 @@ The following sections provide details about properties that are used to define
62
62
63
63
## Linked service properties
64
64
65
-
The following properties are supported for Presto linked service:
65
+
The Presto connector now supports version 2.0 (Preview). Refer to this section to upgrade your Presto connector version from version 1.0. For the property details, see the corresponding sections.
66
+
67
+
-[Version 2.0 (Preview)](#version-20-preview)
68
+
-[Version 1.0](#version-10)
69
+
70
+
### Version 2.0 (Preview)
71
+
72
+
The Presto linked service supports the following properties when apply version 2.0 (Preview):
73
+
74
+
| Property | Description | Required |
75
+
|:--- |:--- |:--- |
76
+
| type | The type property must be set to: **Presto**| Yes |
77
+
| version | The version that you specify. The value is `2.0`. | Yes |
78
+
| host | The IP address or host name of the Presto server. (e.g. 192.168.222.160) | Yes |
79
+
| catalog | The catalog context for all request against the server. | Yes |
80
+
| port | The TCP port that the Presto server uses to listen for client connections. The default value is 8443. | No |
81
+
| authenticationType | The authentication mechanism used to connect to the Presto server. <br/>Allowed values are: **Anonymous**, **LDAP**| Yes |
82
+
| username | The user name used to connect to the Presto server. | No |
83
+
| password | The password corresponding to the user name. Mark this field as a SecureString to store it securely, or [reference a secret stored in Azure Key Vault](store-credentials-in-key-vault.md). | No |
84
+
| enableSsl | Specifies whether the connections to the server are encrypted using TLS. The default value is true. | No |
85
+
| enableServerCertificateValidation | Specify whether to enable server SSL certificate validation when you connect. <br>Always use System Trust Store. The default value is true. | No |
86
+
| timeZoneID | The local time zone used by the connection. Valid values for this option are specified in the IANA Time Zone Database. The default value is null. | No |
87
+
88
+
**Example:**
89
+
90
+
```json
91
+
{
92
+
"name": "PrestoLinkedService",
93
+
"properties": {
94
+
"type": "Presto",
95
+
"version" : "2.0",
96
+
"typeProperties": {
97
+
"host" : "<host>",
98
+
"catalog" : "<catalog>",
99
+
"port" : 8443,
100
+
"authenticationType" : "LDAP",
101
+
"username" : "<username>",
102
+
"password": {
103
+
"type": "SecureString",
104
+
"value": "<password>"
105
+
},
106
+
"enableSsl": true,
107
+
"enableServerCertificateValidation": true,
108
+
"timeZoneID" : ""
109
+
}
110
+
}
111
+
}
112
+
```
113
+
114
+
### Version 1.0
115
+
116
+
The Presto linked service supports the following properties when apply version 1.0:
66
117
67
118
| Property | Description | Required |
68
119
|:--- |:--- |:--- |
@@ -180,10 +231,57 @@ To copy data from Presto, set the source type in the copy activity to **PrestoSo
180
231
]
181
232
```
182
233
234
+
## Data type mapping for Presto
235
+
236
+
When you copy data from Presto, the following mappings apply from Presto's data types to the internal data types used by the service. To learn about how the copy activity maps the source schema and data type to the sink, see [Schema and data type mappings](copy-activity-schema-and-type-mapping.md).
237
+
238
+
| Presto data type | Interim service data type (for version 2.0 (Preview)) | Interim service data type (for version 1.0) |
239
+
|:--- |:--- |:--- |
240
+
| ARRAY | String | String |
241
+
| BIGINT | Int64 | Int64 |
242
+
| BOOLEAN | Boolean | Boolean |
243
+
| CHAR | String | String |
244
+
| DATE | Date | Datetime |
245
+
| DECIMAL (Precision < 28) | Decimal | Decimal |
246
+
| DECIMAL (Precision >= 28) | Decimal | String |
247
+
| DOUBLE | Double | Decimal |
248
+
| INTEGER | Int32 | Int32 |
249
+
| INTERVAL_DAY_TO_SECOND | TimeSpan | Not supported. |
250
+
| INTERVAL_YEAR_TO_MONTH | String | Not supported. |
251
+
| IPADDRESS | String | Not supported. |
252
+
| JSON | String | String |
253
+
| MAP | String | String |
254
+
| REAL | Single | Single |
255
+
| ROW | String | String |
256
+
| SMALLINT | Int16 | Int16 |
257
+
| TIME | Time | TimeSpan |
258
+
| TIME_WITH_TIME_ZONE | String | String |
259
+
| TIMESTAMP | Datetime | Datetime |
260
+
| TIMESTAMPWITHTIMEZONE | Datetimeoffset | Not supported. |
261
+
| TINYINT | SByte | Int16 |
262
+
| UUID | Guid | Not supported. |
263
+
| VARBINARY | Byte[]| Byte[]|
264
+
| VARCHAR | String | String |
265
+
183
266
## Lookup activity properties
184
267
185
268
To learn details about the properties, check [Lookup activity](control-flow-lookup-activity.md).
186
269
270
+
## Upgrade the Presto connector
271
+
272
+
Here are steps that help you upgrade the Presto connector:
273
+
274
+
1. In **Edit linked service** page, select version 2.0 (Preview) and configure the linked service by referring to [linked service version 2.0 (Preview) properties](#version-20-preview).
275
+
276
+
2. The data type mapping for the Presto linked service version 2.0 (Preview) is different from that for the version 1.0. To learn the latest data type mapping, see [Data type mapping for Presto](#data-type-mapping-for-presto).
277
+
278
+
## Differences between Presto connector version 2.0 (Preview) and version 1.0
279
+
280
+
The Presto connector version 2.0 (Preview) offers new functionalities and is compatible with most features of version 1.0. The following table shows the feature differences between version 2.0 (Preview) and version 1.0.
281
+
282
+
| Version 2.0 (Preview) | Version 1.0 |
283
+
| :----------- | :------- |
284
+
| The following mappings are used from Presto data types to interim service data type.<br><br>DATE -> Date <br>DECIMAL (Precision >= 28) -> Decimal <br> DOUBLE -> Double <br>INTERVAL_DAY_TO_SECOND -> TimeSpan <br>INTERVAL_YEAR_TO_MONTH -> String<br>IPADDRESS -> String<br>TIME -> Time<br>TIMESTAMPWITHTIMEZONE -> Datetimeoffset<br>TINYINT -> SByte<br>UUID -> Guid| The following mappings are used from Presto data types to interim service data type.<br><br>DATE -> Datetime <br>DECIMAL (Precision >= 28) -> String <br>DOUBLE -> Decimal <br>TIME -> TimeSpan<br>TINYINT -> Int16<br> Other mappings supported by version 2.0 (Preview) listed left are not supported by version 1.0. |
187
285
188
286
## Related content
189
287
For a list of data stores supported as sources and sinks by the copy activity, see [supported data stores](copy-activity-overview.md#supported-data-stores-and-formats).
0 commit comments