mysql-poolastic

1.0.4 • Public • Published

how to use with express

"use strict"
var express = require('express')
var mysqlPoolastic = require('mysql-poolastic');

var app = new express()

mysqlPoolastic.config({
    connectionLimit: 100, //important
    host: 'localhost',
    user: 'root',
    password: '',
    database: 'address_book',
    debug: false
})

// for querying:
app.get("/", function(req, res) {
    // print out a list of users
    mysqlPoolastic.query("SELECT * FROM users", req, res)
})
app.listen(8080)

Readme

Keywords

none

Package Sidebar

Install

npm i mysql-poolastic

Weekly Downloads

0

Version

1.0.4

License

ISC

Last publish

Collaborators

  • michelemilani