这个Javascript“要求”是什么?
我正在尝试让Javascript读取/写入PostgreSQL数据库。我在github上找到了这个项目。我能够获得以下示例代码以在节点中运行。 var pg = require('pg'); //native libpq bindings = `var pg = require('pg').native` var conString = "tcp://postgres:1234@localhost/postgres"; var client = new pg.Client(conString); client.connect(); //queries are queued and executed one after another once the connection becomes available client.query("CREATE TEMP TABLE beatles(name varchar(10), height integer, birthday timestamptz)"); client.query("INSERT INTO beatles(name, height, birthday) …