Constructor
new MysqlPool(config)
Create pool connections
Parameters:
Name | Type | Description |
---|---|---|
config |
object | connection options (https://github.com/mysqljs/mysql#connection-options) |
Methods
query(q, dataopt) → {Promise}
Run queries
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
q |
string | MySQL Queries | ||
data |
array |
<optional> |
[]
|
Query parameters (https://github.com/mysqljs/mysql#escaping-query-values) |
Returns:
- Type
- Promise