UNPKG

access-db

Version:

[统一数据库的连接]Unified access to all kinds of databases

39 lines (38 loc) 2.81 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ORDER_BY_NOT_ARRAY = exports.SELECT_NOT_ARRAY = exports.ID_EMPTY_ERROR = exports.FASTDB_UPDATE_JSON_ERROR = exports.FASTDB_UPDATE_ID_ERROR = exports.FASTDB_HAVE_ID_ERROR = exports.FASTDB_GET_ID_ERROR = exports.FASTDB_FILE_ERROR = exports.TRAN_P_ERROR = exports.SET_MANY_PARAMS_ARR_ERROR = exports.FIND_J_JOIN_ERROR = exports.FIND_P_BETWEEN_ERROR = exports.PARAM_TABLE_ERROR = exports.GEO_POLYGON_ERROR = exports.QUEUE_METHOD_ERROR = exports.PARAMS_EMPTY_ARR_ERROR = exports.PARAMS_NOT_ARR_ERROR = exports.FIND_J_ERROR = exports.FIND_NO_PJ_ERROR = exports.FIND_P_ERROR = exports.UPDATE_ERROR = exports.FIND_CHECKR_ERROR = exports.FIND_R_ERROR = exports.INIT_ENV_ERROR = void 0; exports.INIT_ENV_ERROR = 'Make sure that variables such as HOST are defined in the .env file.'; exports.FIND_R_ERROR = 'Lookup rule r is not defined.'; exports.FIND_CHECKR_ERROR = 'The brackets in the search rule r do not correspond (in pairs).'; exports.UPDATE_ERROR = 'The params(params) is not in the correct format.'; exports.FIND_P_ERROR = 'The p parameter (p0-p19) is wrong.'; exports.FIND_NO_PJ_ERROR = 'Undefined parameter:'; exports.FIND_J_ERROR = 'The j parameter (j0 ~ j5) is wrong.'; // mysql in not in等,参数必须为有值数组 exports.PARAMS_NOT_ARR_ERROR = 'The params should be array.'; exports.PARAMS_EMPTY_ARR_ERROR = 'The params should be array, and not empty.'; //redis exports.QUEUE_METHOD_ERROR = 'The Redis queue method is not defined.'; //geo exports.GEO_POLYGON_ERROR = 'Polygon type, the number of points should be at least 3, and the first and last points should be the same. So the length of the passed in parameter is at least 4.'; exports.PARAM_TABLE_ERROR = 'The table parameter cannot be empty.'; //between参数个数 exports.FIND_P_BETWEEN_ERROR = 'The between method requires two parameters.'; //join exports.FIND_J_JOIN_ERROR = 'The join method requires two fields.'; //setMany exports.SET_MANY_PARAMS_ARR_ERROR = 'The params method argument should be array object.'; //事务错误 exports.TRAN_P_ERROR = 'The transaction parameter list is an array and cannot be empty.'; // fastdb exports.FASTDB_FILE_ERROR = 'Table(a json file) not exists.'; exports.FASTDB_GET_ID_ERROR = 'The id should not be undefined.'; exports.FASTDB_HAVE_ID_ERROR = 'The id is already exists.'; exports.FASTDB_UPDATE_ID_ERROR = 'The id can not be a param.'; exports.FASTDB_UPDATE_JSON_ERROR = 'The parmas name use too many point.'; // mongodb exports.ID_EMPTY_ERROR = 'The update/updatemany method, key(exp: _id) could not be empty'; // select should be array exports.SELECT_NOT_ARRAY = 'The find params.select must be array.'; // orderBy should be array exports.ORDER_BY_NOT_ARRAY = 'The find params.orderBy must be array.';