6
この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) …