Guest User

Untitled

a guest
May 3rd, 2018
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. var mysql = require('mysql');
  2. var config = require('./../Config.js');
  3.  
  4. var connection = mysql.createConnection({
  5. host: config.databaseConnection.host ,
  6. user: config.databaseConnection.user,
  7. password: config.databaseConnection.password,
  8. database: config.databaseConnection.database
  9. });
  10.  
  11. var executeQuery = function (querystring) {
  12.  
  13.  
  14.  
  15. connection.connect(function (err) {
  16.  
  17. if (err) throw err;
  18. console.log("connected to database successfully");
  19.  
  20. });
  21.  
  22. }
  23.  
  24.  
  25. module.exports = connection;
Add Comment
Please, Sign In to add comment