INSERT INTO gorfs.nfs_data (owner_id, file_id, migration_path,
    migration_date)
                 VALUES (SELECT
                   file.parent_inode_id AS owner_id,
                   file.inode_id        AS file_id,
                   file.node_full_path  AS file_name,
                   file.last_modified   AS date_created
                 FROM
                   gorfs.nodes AS file
                 WHERE (file.last_modified < (transaction_timestamp() AT
    TIME ZONE 'UTC' - '1 months' :: INTERVAL)))


Estou no caminho certo? hehehe

Não precisa do VALUES e dos parênteses en volta do SELECT. O resto parece Ok.

[]s
Flavio Gurgel
_______________________________________________
pgbr-geral mailing list
pgbr-geral@listas.postgresql.org.br
https://listas.postgresql.org.br/cgi-bin/mailman/listinfo/pgbr-geral

Responder a