{"size": 450, "ext": "js", "max_stars_repo_path": "routes/modules/Db.js", "max_stars_repo_name": "Astrian/oa-node.js", "max_stars_repo_stars_event_min_datetime": "2017-05-02T11:19:22.000Z", "max_stars_repo_stars_event_max_datetime": "2021-08-13T11:29:12.000Z", "max_issues_repo_path": "routes/modules/Db.js", "max_issues_repo_name": "zhanglei518/oa-node.js", "max_issues_repo_issues_event_min_datetime": "2018-10-14T02:06:51.000Z", "max_issues_repo_issues_event_max_datetime": "2018-10-16T09:49:36.000Z", "max_forks_repo_path": "routes/modules/Db.js", "max_forks_repo_name": "zhanglei518/oa-node.js", "max_forks_repo_forks_event_min_datetime": "2018-07-02T23:34:54.000Z", "max_forks_repo_forks_event_max_datetime": "2020-08-13T03:50:08.000Z"}
{"max_stars_count": 13, "max_issues_count": 1, "max_forks_count": 5, "avg_line_length": 25.0, "max_line_length": 59, "alphanum_fraction": 0.6488888889}
var mysql = require('mysql');
var debug = require('debug')('oa:moudle/db')
var connection = mysql.createPool({
  host: 'localhost',
  user: 'root',
  password: 'root',
  database: 'oa-new',
  charset: 'utf8mb4_unicode_ci'
});
exports.exec = function (sql, back) {
  connection.getConnection(function (err, connection) {
    connection.query(sql, function (err, results, fields) {
      back(err, results);
      connection.release();
    });
  });
}
