Connect Soda to Google CloudSQL

Access configuration details to connect Soda to a Google CloudSQL data source.

For Soda to run quality scans on your data, you must configure it to connect to your data source. To learn how to set up Soda and configure it to connect to your data sources, see Get started.

Connection configuration reference

Because Google CloudSQL is compatible with PostgreSQL wire protocol, Soda offers support for Google CloudSQL data sources using the soda-postgres package.

data_source my_datasource_name:
  type: postgres
  host: db
  port: "5432"
  username: simple
  password: simple_pass
  database: postgres
  schema: public
Property
Required
Notes

type

required

Identify the type of data source for Soda.

host

required

Provide a host identifier.

port

required

Provide a port identifier.

username

required

Consider using system variables to retrieve this value securely.

password

required

Consider using system variables to retrieve this value securely.

database

required

Identify the name of your database.

schema

required

Provide an identifier for the schema in which your table exists.

Test the data source connection

To confirm that you have correctly configured the connection details for the data source(s) in your configuration YAML file, use the test-connection command. If you wish, add a -V option to the command to return results in verbose mode in the CLI.

soda test-connection -d my_datasource -c configuration.yml -V

Supported data types

Category
Data type

text

CHARACTER VARYING, CHARACTER, CHAR, TEXT

number

SMALLINT, INTEGER, BIGINT, DECIMAL, NUMERIC, VARIABLE, REAL, DOUBLE PRECISION, SMALLSERIAL, SERIAL, BIGSERIAL

time

TIMESTAMP, DATE, TIME, TIMESTAMP WITH TIME ZONE, TIMESTAMP WITHOUT TIME ZONE, TIME WITH TIME ZONE, TIME WITHOUT TIME ZONE

Last updated

Was this helpful?