# How to Integrate GCP MySQL with Daton

### Prerequisites

Before we get started, make sure you have:

* A GCP MySQL and a Daton account
* GCP MySQL Host Name
* GCP MySQL Port Number
* GCP MySQL User Name
* GCP MySQL User Password
* GCP MySQL Database Name

### Integrate your GCP MySQL Database with Daton

* Log in to your [Daton account](https://daton.sarasanalytics.com/u/integrations-list) and search for GCP MySQL in the list of Connectors, then click **Configure**.
* Enter the following details and click **Authenticate**:&#x20;

  * Integration Name
    * Optionally, add a description to identify the integration.
  * Replication Frequency&#x20;
  * Replication Start Date

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2FaVLY5hxtFvlYkGKDOUlm%2F1GCP%20MYSQL%20Source.png?alt=media&#x26;token=e9036d78-d142-46b4-8d7f-d1cdb5712bf1" alt=""><figcaption></figcaption></figure>

  **Note** that the Integration Name will be used to create the integration tables and cannot be modified later.
* Provide the following GCP MySQL credentials and click **Next.**&#x20;

  * GCP MySQL Host Name
  * GCP MySQL Port Number
  * GCP MySQL User Name
  * GCP MySQL User Password
  * GCP MySQL Database Name

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2F8ZneoS7KyHAaOphbm34F%2F2GCP%20MYSQL%20Source.png?alt=media&#x26;token=7e542007-159c-4f52-9a60-b7293cf440c2" alt=""><figcaption></figcaption></figure>

  You can also secure your authentication by SSH tunneling. You can find this option at the bottom of this page.

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2FFoUCNqTyboly9QupkXIf%2F6Redshift%20Source%20SSH.png?alt=media&#x26;token=20ac1c78-cf96-4f77-b9da-100c530fa59c" alt="" width="375"><figcaption></figcaption></figure>

  For further information, refer to the FAQs section on ["How to Enable SSH Tunneling during a Database Source Authentication?"](https://daton-sarasanalytics.gitbook.io/daton/faqs/faqs/how-to-enable-ssh-tunneling-during-a-database-source-authentication)
* Post Database Authentication, you will be prompted to choose schemas from the list. **Select** the desired Schemas and click **Next.** &#x20;

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2FRy2Vo3oqhAgnPVDwqefX%2F3GCP%20MYSQL%20Source.png?alt=media&#x26;token=73dbb167-1488-49a3-a674-bc0044c92257" alt=""><figcaption></figcaption></figure>
* **Select** all the Tables as per requirement and **Configure** the schema that you wish to create in the destination before clicking the **Next** button.&#x20;

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2F2eYgfylD3MjdKnG5TwGQ%2F4GCP%20MYSQL%20Source.png?alt=media&#x26;token=7ed8dd1a-140a-4c4d-889d-3605265c5345" alt=""><figcaption></figcaption></figure>

  **Note**:&#x20;

  * You will have to check at least one Table from each of the previously selected Schemas to proceed further.&#x20;
    * You can also customize the replication frequency and replication start date of each desired table separately. You may find this functionality under the advanced settings of every selected table.
    * Select all the Columns you require for each table and **Submit** the integration.&#x20;

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2Fsc8jxObVGNW9UNNWFeJj%2F5GCP%20MYSQL%20Source.png?alt=media&#x26;token=4e2a803c-ff8d-4a7a-986a-9616e9a7f09f" alt=""><figcaption></figcaption></figure>

  It's recommended to select a replication field for each of the tables. Selecting **'None'** will lead to full table replication. Learn more about [Replication Fields](https://daton-sarasanalytics.gitbook.io/daton/platform/features/data/data-replication-in-daton/replication-fields) here.

  <figure><img src="https://15515196-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LbJ1eMq5M51cIpU163R%2Fuploads%2FLKk3uVWN3etl29L1MAk0%2FRedshift%20Source.png?alt=media&#x26;token=09b5d5ed-79d9-4ab8-9d0e-b511e49afe0f" alt="" width="375"><figcaption></figcaption></figure>

  \
  **Note** that you will be prompted to select the destination for your Database.
* Select the destination for your store or shop and click **Confirm**. An integration successful message will be displayed.

## Important Note

* Integrations would begin in the Pending state and change to the Active state once the first job successfully loaded data into the configured warehouse.&#x20;
* Users can check job status and process logs from the integration details page by clicking on the integration name in the active list.&#x20;
* Users can Re-Authenticate, Edit, Clone, Pause, or Delete the integration at any moment by clicking on settings. You can also adjust the frequency and history of the integration.&#x20;
* On the Sources page, click Integration to access each table in your integration. The page also shows the state of each table, the last replicated time, and the Reload access buttons.&#x20;
