Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOCS] Revise OSS Installation and Setup Guidance for SQL Data Sources #9609

Merged
merged 2 commits into from
Mar 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ To validate Google Cloud Platform (GCP) data with GX Core, you create your GX Py
## Prerequisites

- <PrereqPythonInstalled/>
- pip can be used to install Python modules.
- pip. See [Installation and downloads](https://pypi.org/project/pip/).
- A [GCP service account](https://cloud.google.com/iam/docs/service-account-overview) with permissions to access GCP resources and storage Objects.
- The `GOOGLE_APPLICATION_CREDENTIALS` environment variable is set. See [Set up Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc).
- Google Cloud API authentication is set up. See [Set up authentication](https://cloud.google.com/storage/docs/reference/libraries#authentication).
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,69 @@
---
title: Install and set up SQL Data Source support
---
import InProgress from '../../_core_components/_in_progress.md';

<InProgress />
import PrereqPythonInstalled from '../../_core_components/prerequisites/_python_installation.md';

To validate data stored on SQL databases with GX Core, you create your GX Python environment, install GX Core locally, and then configure the necessary dependencies.

## Prerequisites

- <PrereqPythonInstalled/>
- pip. See [Installation and downloads](https://pypi.org/project/pip/).
- The necessary environment variables are set to allow access to the SQL database. See [Manage credentials](../manage_credentials.md).

## Installation

## Next steps
1. Run the following code to confirm your Python version:

```bash title="Terminal input"
python --version
```
If your existing Python version is not 3.8 to 3.11, see [Active Python Releases](https://www.python.org/downloads/).

2. Run the following code to create a virtual environment and a directory named `my_venv`:

```bash title="Terminal input"
python -m venv my_venv
```
Optional. Replace `my_venv` with another directory name.

If you prefer, you can use virtualenv, pyenv, and similar tools to install GX in virtual environments.

3. Run the following code to activate the virtual environment:

```bash title="Terminal input"
source my_venv/bin/activate
```

4. Run the following code to install optional dependencies for SQLAlchemy:

```bash title="Terminal input"
python -m pip install 'great_expectations[sqlalchemy]'
```
To install optional dependencies for a different SQL database, see [SQL database dependency commands](#sql-database-dependency-commands).

5. Run the following code to confirm GX was installed successfully:

```bash title="Terminal input"
great_expectations --version
```
The output should be `great_expectations, version <version_number>`.

## SQL database dependency commands

The following table lists the installation commands used to install GX Core dependencies for specific SQL databases. These dependencies are required for the successful operation of GX Core.

| SQL Database | Command |
| :-- | :-- |
| AWS Athena | `pip install 'great_expectations[athena]'` |
| BigQuery | `pip install 'great_expectations[bigquery]'` |
| MSSQL | `pip install 'great_expectations[mssql]'` |
| PostgreSQL | `pip install 'great_expectations[postgresql]'` |
| Redshift | `pip install 'great_expectations[redshift]'` |
| Snowflake | `pip install 'great_expectations[snowflake]'` |
| Trino | `pip install 'great_expectations[trino]'` |

## Next steps

- [Manage Data Contexts](/core/installation_and_setup/manage_data_contexts.md)
2 changes: 1 addition & 1 deletion docs/docusaurus/sidebars.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ module.exports = {
{
type: 'doc',
id: 'core/installation_and_setup/additional_dependencies/sql_data_sources',
label: '🚧 SQL Data Sources'
label: 'SQL Data Sources'
},
]
},
Expand Down