12345678910111213141516171819202122232425262728 |
- // 此文件暂时不用
- // 此文件暂时不用
- // 此文件暂时不用
- // 此文件暂时不用
- // 此文件暂时不用
- // 此文件暂时不用
- // 此文件暂时不用
- const pgClient = require("../Postgresql/pgClient2.js")
- //执行 单条 查询语句
- // 返回一个 Promise
- const doQuery = function (sqlstr) {
- return new Promise((resolve, reject) => {
- pgClient.query(sqlstr, function (err, result) {
- if (!err) {
- resolve(result)
- } else {
- reject(err)
- }
- });
- })
- }
- module.exports = {
- doQuery
- }
|