docs: multiple small fixes around databases (#14321)

* docs: multiple small fixes around databases

* add link to postgres SSL options
This commit is contained in:
Srini Kadamati 2021-04-28 10:30:28 -04:00 committed by GitHub
parent 43ee52be57
commit bbdb4ee24f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 29 additions and 20 deletions

View File

@ -8,21 +8,16 @@ version: 1
## MySQL ## MySQL
The recommended connector library for MySQL is [mysqlclient](https://pypi.org/project/mysqlclient/). The recommended connector library for MySQL is [mysql-connector-python](https://pypi.org/project/mysql-connector-python/).
Set up the Connection String using the following settings: Here's the connection string:
User Name: UserName ```
Password: DBPassword mysql+mysqlconnector://{username}:{password}@{host}/{database}
Database Host: ```
- For Localhost or docker running Linux: localhost or 127.0.0.1
Host:
- For Localhost or Docker running Linux: `localhost` or `127.0.0.1`
- For On Prem: IP address or Host name - For On Prem: IP address or Host name
- For AWS Endpoint - For Docker running in OSX: `docker.for.mac.host.internal`
- For Docker running in OSX: docker.for.mac.host.internal Port: `3306` by default
Database Name: Database Name
Port: default 3306
Connection String
```
mysql://<UserName>:<DBPassword>@<Database Host>/<Database Name>
```

View File

@ -25,15 +25,18 @@ Postgres sample connection parameters:
The connection string looks like: The connection string looks like:
``` ```
postgresql+psycopg2://{username}:{password}@{host}:{port}/{database} postgresql://{username}:{password}@{host}:{port}/{database}
``` ```
Extra parameters: You can require SSL by adding `?sslmode=require` at the end:
``` ```
?sslmode=require postgresql://{username}:{password}@{host}:{port}/{database}?sslmode=require
``` ```
You can read about the other SSL modes that Postgres supports in
[Table 31-1 from this documentation](https://www.postgresql.org/docs/9.1/libpq-ssl.html).
More information about PostgreSQL connection options can be found in the More information about PostgreSQL connection options can be found in the
[SQLAlchemy docs](https://docs.sqlalchemy.org/en/13/dialects/postgresql.html#module-sqlalchemy.dialects.postgresql.psycopg2) [SQLAlchemy docs](https://docs.sqlalchemy.org/en/13/dialects/postgresql.html#module-sqlalchemy.dialects.postgresql.psycopg2)
and the and the

View File

@ -14,13 +14,24 @@ The expected connection string is formatted as follows:
``` ```
presto://{hostname}:{port}/{database} presto://{hostname}:{port}/{database}
e.g. ```
presto://presto.example.com:8080/hive
You can pass in a username and password as well:
```
presto://{username}:{password}@{hostname}:{port}/{database}
```
Here is an example connection string with values:
```
presto://datascientist:securepassword@presto.example.com:8080/hive
``` ```
By default Superset assumes the most recent version of Presto is being used when querying the By default Superset assumes the most recent version of Presto is being used when querying the
datasource. If youre using an older version of Presto, you can configure it in the extra parameter: datasource. If youre using an older version of Presto, you can configure it in the extra parameter:
``` ```
{ {
"version": "0.123" "version": "0.123"