Remove unneeded pg_catalog schema name

This commit is contained in:
Javier Goizueta
2016-04-25 16:30:58 +02:00
parent 65415bb335
commit 11ad45306f
3 changed files with 9 additions and 9 deletions

View File

@@ -5,9 +5,9 @@ AS $$
SELECT
a.attname::information_schema.sql_identifier column_name
FROM pg_class c
LEFT JOIN pg_catalog.pg_attribute a ON a.attrelid = c.oid
LEFT JOIN pg_attribute a ON a.attrelid = c.oid
WHERE c.oid = $1::oid
AND a.attstattarget = -1
AND a.attstattarget < 0 -- exclude system columns
ORDER BY a.attnum;
$$ LANGUAGE SQL;