> And. If I'm not connected to any database. Can I execute a file that makes a
> query on a database?
Sorry, I made a mistake
psql -f <filename> -U <user> <database>
I'm not sure, but you can add export PGPASSWORD=<password> before this
command if you need a password.
Tomasz Myrta