Skip to main content

Querying a table


SQL support in RAW is currently in Closed Beta. Contact us for early access.


This document is a work-in-progress. Check back soon!

The first step is to establish a new database connection by adding a new RDBMS RAW credential. Consider our publicly accessible PostgreSQL database. You can add this database as a RAW credential either programmatically using our API, or through our UI by following this guide. After the credential is added, all tables within the specified schema become available for querying on our platform.

example schema

As shown above, within the example schema, you will find the following table:

airport_id integer,
name varchar(256),
city varchar(512),
country varchar(512),
iata_faa varchar(3),
icao varchar(6),
latitude numeric(9,6),
longitude numeric(9,6),
altitude numeric(9,3),
timezone integer,
dst varchar(128),
tz varchar(256)

This table lists airports from around the globe. Since we've loaded all tables in the example schema, the airports table is readily available for querying.

Indicatively, to retrieve all airports in Iceland, you can use the following query:

SELECT * FROM <credential_name>.airports WHERE country='Iceland';

Note that <credential_name> refers to the name of the PostgreSQL credential specified in RAW, which also corresponds to the schema acting as a clone of the remote PostgreSQL schema, such as 'example'. If this credential is named local_schema, then the aforementioned query would be formulated as follows:

SELECT * FROM local_schema.airports WHERE country='Iceland';

Example 1 - Results