SQL

SQL

Made by DeepSource

Confusing use of USING operator SQL-L032

Style
Minor

Prefer specifying JOIN of keys instead of relying on USING operator. Certain warehouses have inconsistencies in USING results (specifically Snowflake).

Bad practice

SELECT
    table_a.field_1,
    table_b.field_2
FROM
    table_a
INNER JOIN table_b USING (id)

Recommended

SELECT
    table_a.field_1,
    table_b.field_2
FROM
    table_a
INNER JOIN table_b
    ON table_a.id = table_b.id