psql allows you to send SQL messages to a PostgreSQL database from Pd and retrieve the results. Please check the README file after installation. Untested for 64-bit, please inform on success.