mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-30 03:22:14 +00:00
d91c97d15d
* Replace underscores with hyphens * remove temporary code * fix style check * fix collapse
28 lines
733 B
Markdown
28 lines
733 B
Markdown
---
|
|
toc_priority: 43
|
|
toc_title: jdbc
|
|
---
|
|
|
|
# jdbc {#table-function-jdbc}
|
|
|
|
`jdbc(jdbc_connection_uri, schema, table)` - returns table that is connected via JDBC driver.
|
|
|
|
This table function requires separate `clickhouse-jdbc-bridge` program to be running.
|
|
It supports Nullable types (based on DDL of remote table that is queried).
|
|
|
|
**Examples**
|
|
|
|
``` sql
|
|
SELECT * FROM jdbc('jdbc:mysql://localhost:3306/?user=root&password=root', 'schema', 'table')
|
|
```
|
|
|
|
``` sql
|
|
SELECT * FROM jdbc('mysql://localhost:3306/?user=root&password=root', 'schema', 'table')
|
|
```
|
|
|
|
``` sql
|
|
SELECT * FROM jdbc('datasource://mysql-local', 'schema', 'table')
|
|
```
|
|
|
|
[Original article](https://clickhouse.tech/docs/en/query_language/table_functions/jdbc/) <!--hide-->
|