Skip to main content

SQL

Connecting to a Database

The SQL dataset operator can be used to create a dataset from within a canvas, using data connectors that have already been configured. From the operator's left menu, select or create a data connector.

Next, write a SQL query. The result of the query will then be available as an output dataframe. This SQL result can then be used in another SQL cell, a Python cell, or any no code cell as well.

SQL Over Dataframes

Any dataframe can be used as an input into a SQL cell; it does not need to be a database connection. For instance, you can bring the output of a Python cell into the SQL cell, and operate over that Pandas dataframe using more straightforward SQL syntax.

This way, you can use either Python or SQL to manipulate data, depending on what syntax and which logic makes more sense.