title: Set encrypted postgres password without entering it as SQL
body: <p>I set up a postgres DB on my server, logged in with postgres (PEER Method), created another user and than want to set an encrypted password for the new user.</p>
  
  <p>The most tutorials I find say, that you can change the password by:</p>
  
  <pre><code>ALTER USER other_user WITH ENCRYPTED PASSWORD 'passwd';
  </code></pre>
  
  <p>But it does not really feel good to enter the password clear into the sql console. It is saved in the history, and everybody can see it.</p>
  
  <p>Is this really the right way to set a password in postgres?</p>