You can write complex filters for any table that is part of the dimensions/measures.
Example columns in Dimensions/Measures: "public_table1"."country", "public_table2"."location", "public_table1"."population"
For the above, below will be our generated SQL:
Copy
SELECT "public_table1"."country" AS "country", "public_table2"."location" AS "location", "public_table1"."population" AS "population"FROM "public"."table1" AS "public_table1" INNER JOIN "public"."table2" AS "public_table2" ON "public_table2"."code" = "public_table1"."code"LIMIT 100
When writing a custom SQL query, the complex filter can only address columns of the table "dbn_sql_table".
Example Custom SQL that you write:
Copy
SELECT "country" AS "country", "population" AS "population"FROM "public"."table"
The SQL generated by us:
Copy
SELECT "country" AS "country", "population" AS "population"FROM( SELECT "country" AS "country", "population" AS "population" FROM "public"."table") AS "dbn_sql_table"