Hi On Tue, Dec 1, 2015 at 12:41 PM, Wizz <mast...@gmail.com> wrote: > How can I access the SQL that executes when I alter my tables with the > pgAdmin interface. > For instance, if I add a column, without a doubt, there was a "ALTER TABLE > tablename ADD COLUMN column name int;" executed in the background. How do I > get to it? > I need to make a bunch of changes to a database and then have those changes > in the form of SQL so I can pass it on to a colleague, who will execute it > on an identical database. > Thank you!
You can either: - Turn up the log level to include SQL, and extract the statements from the log (though that can be a pain as there's a lot of additional stuff there), or; - Click on the SQL tab on each dialogue you make changes in, before you hit OK. That'll show you the SQL that will be executed by the changes you've made in the dialogue. -- Dave Page Blog: http://pgsnake.blogspot.com Twitter: @pgsnake EnterpriseDB UK: http://www.enterprisedb.com The Enterprise PostgreSQL Company -- Sent via pgadmin-support mailing list (pgadmin-support@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-support