title: pg_config - how to change postgres versions
body: <p>By default I had postgres 10 versions on my two ubuntu 14 machines, but I installed postgres 9.6 on the two of them.</p>
  
  <p>But on one of them pg_config give me:</p>
  
  <pre><code>VERSION = PostgreSQL 9.6.6
  </code></pre>
  
  <p>And the other:</p>
  
  <pre><code>VERSION = PostgreSQL 10.1
  </code></pre>
  
  <p>They have the same libpq-dev packages in:</p>
  
  <pre><code>dpkg -l | grep libpq-dev
  
  libpq-dev  10.1-1.pgdg14.04+1  amd64 header files for libpq5 (PostgreSQL library)
  </code></pre>
  
  <p>So I was wondering is there a way for me to change the version installed that it gives me postgres 9.6 instead of postgres 10.01? Maybe using the pg_config file?</p>
  
  <p>Tnx,
  Tom</p>
  
  <p>update:
  on the instance that still shows postgres 10, this is the result(which shows that it is not installed):</p>
  
  <pre><code>ii  pgdg-keyring                         2017.3                                     all          keyring for apt.postgresql.org
  ii  postgresql-9.6                       9.6.6-1.pgdg14.04+1                        amd64        object-relational SQL database, version 9.6 server
  ii  postgresql-client-9.6                9.6.6-1.pgdg14.04+1                        amd64        front-end programs for PostgreSQL 9.6
  ii  postgresql-client-common             189.pgdg14.04+1                            all          manager for multiple PostgreSQL client versions
  ii  postgresql-common                    189.pgdg14.04+1                            all          PostgreSQL database-cluster manager
  ii  postgresql-contrib-9.6               9.6.6-1.pgdg14.04+1                        amd64        additional facilities for PostgreSQL
  </code></pre>