You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This just popped up starting with node v0.5.10. I am not able to get any query to work. The pg module seems to connect to the database, but it gets an error when it runs a query.
Here is some sample code that will produce this error:
var pg = require('pg'),
util = require('util');
var connectstring = 'pg://user:password@127.0.0.1/db1';
function getTheTime() {
pg.connect(connectstring, function (err, client) {
if (err) util.log('Error with pg.connect!'), util.log(util.inspect(err));
else client.query('SELECT now() as when', function (err, result) {
if (err) util.log('Error with client.query!'), util.log(util.inspect(err));
else util.log('The postres time is: ' + result.rows[0].when);
});
});
}
getTheTime();
I don't know what invalid string in message means or even where to begin looking in the module code. I tried it with postgres v8.4, and with postgres v9.0.
Per the node blog, node v0.5.10 is supposed to be the last version before node v0.6.
The text was updated successfully, but these errors were encountered:
This just popped up starting with node v0.5.10. I am not able to get any query to work. The pg module seems to connect to the database, but it gets an error when it runs a query.
Here is some sample code that will produce this error:
This gives the following output:
I don't know what
invalid string in message
means or even where to begin looking in the module code. I tried it with postgres v8.4, and with postgres v9.0.Per the node blog, node v0.5.10 is supposed to be the last version before node v0.6.
The text was updated successfully, but these errors were encountered: