Skip to content

Instantly share code, notes, and snippets.

@brianc
Created November 12, 2010 23:37
Show Gist options
  • Save brianc/674901 to your computer and use it in GitHub Desktop.
Save brianc/674901 to your computer and use it in GitHub Desktop.
idea for prepared statement api
client.parse('statementName', 'select * from boom where name = $1', Æ(err, statement) {
if(err) {
//do something
}
statement.bind('portalName', ['_alex'], Æ(err, portal) {
if(err) {
//do something
}
portal.execute(10, Æ(err, row) {
if(err) {
//do something
}
console.log(row.name);
});
})
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment