From db0261bf45d4b16390fad4dc52d2f0293e8eee49 Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Fri, 27 Nov 2020 01:01:42 -0500 Subject: [PATCH] no pool --- script.js | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/script.js b/script.js index e56bb8a..7227b4f 100644 --- a/script.js +++ b/script.js @@ -1,21 +1,23 @@ const { Pool, Client } = require('pg') +/* const pool = new Pool({ - user: 'ptrowbridge', + user: 'api', host: '192.168.1.110', database: 'ubm', - password: 'gyaswddh1983', - port: 5432, + password: 'qqqx53!028', + port: 5433, }) pool.query('SELECT NOW()', (err, res) => { console.log(err, res) pool.end() }) +*/ const client = new Client({ - user: 'ptrowbridge', + user: 'api', host: '192.168.1.110', database: 'ubm', - password: 'gyaswddh1983', - port: 5432, + password: 'qqqx53!028', + port: 5433, }) client.connect() client.query('SELECT * from pg_stat_activity', (err, res) => {