This is a small MySQL2 TypeScript wrapper that provides useful functions for promise pools
.
npm i mysql2-ts-pool
https://www.npmjs.com/package/mysql2-ts-pool
- RowDataPacket: Object representing a row returned by the query. Can have any properties.
- FieldPacket: Object containing db metadata.
- OkPacket: Object containing information about the query.
This module will simply typecast the results, so you must use the query for the data you expect.
Establishes the exported pool using PoolOptions
Awaits pool.end()
Runs the execute function, and returns a RowDataPacket
array and a FieldPacket
array.
Runs the execute function, and returns a single RowDataPacket
and a FieldPacket
array.
Runs the query function, and returns a RowDataPacket
array and a FieldPacket
array.
Runs the query function, and returns a single RowDataPacket
and a FieldPacket
array.
Runs the query function, and returns a single OkPacket
Returns raw pool