var mysql = require("mysql");
var con = mysql.createConnection({
host:'localhost',
user:'root',
password:'1234',
database:'zjcpa',
port:3306
});
con.connect();
con.query("select * from cpauser",function(err,rows,fields){
if(err) throw err;
console.log("The solution is:",rows[0].solution);
for(var i in rows){
console.log(rows[i]);
}
});con.end();