title: Is it possible to "CREATE DATABASE ..." with pg-promise and PostgreSQL (9.5)?
body: <p>Question is: </p>
  
  <pre><code>1) Can pg-promise be used to create a new database (schemas, et. al.)?
  </code></pre>
  
  <p>Using node package 'pg-promise' I can't seem to figure out if it's possible to create a new database. I can connect to an existing database and have no issue there. However, when I run without a database name I get an error:</p>
  
  <p>This is what I am trying:</p>
  
  <pre><code>host = host || '127.0.0.1'
  port = port || '5432'
  
  const pgp = require('pg-promise')(pgpInitOptions)
  
  // database connection details
  const pgConnectionOptions = {
    host: host,
    port: port,
    user: user,
    password: pass
  }
  
  // database instance
  const localDB = pgp(pgConnectionOptions)
  
  let escapedDbName = dbName.replace(/\"/g, '""');
  let sql = 'CREATE DATABASE "' + escapedDbName + '"';
  
  localDB
  .any(sql)
  .then((results) =&gt; {
    console.log('creation of database successful', results)
  })
  .catch((error) =&gt; {
    console.error('creation of database failed', error)
  })
  </code></pre>
  
  <p>Then, I get this error:</p>
  
  <pre><code>creation of database failed
  Error: database "jeff" does not exist
  </code></pre>
  
  <p>"jeff" is my ubuntu login name.</p>