@cubejs-backend/athena-driver
Advanced tools
Comparing version 0.10.28 to 0.10.30
@@ -6,2 +6,14 @@ # Change Log | ||
## [0.10.30](https://github.com/statsbotco/cubejs-client/compare/v0.10.29...v0.10.30) (2019-08-26) | ||
### Bug Fixes | ||
* Athena doesn't support `_` in contains filter ([d330be4](https://github.com/statsbotco/cubejs-client/commit/d330be4)) | ||
* Athena doesn't support `'` in contains filter ([40a36d5](https://github.com/statsbotco/cubejs-client/commit/40a36d5)) | ||
## [0.10.28](https://github.com/statsbotco/cubejs-client/compare/v0.10.27...v0.10.28) (2019-08-19) | ||
@@ -8,0 +20,0 @@ |
@@ -5,3 +5,2 @@ const AWS = require('aws-sdk'); | ||
const SqlString = require('sqlstring'); | ||
const crypto = require('crypto'); | ||
@@ -36,7 +35,13 @@ const applyParams = (query, params) => { | ||
setTimeout(() => resolve(), ms); | ||
}) | ||
}); | ||
} | ||
async query(query, values) { | ||
const queryString = applyParams(query, values); | ||
const queryString = applyParams( | ||
query, | ||
values.map(s => (typeof s === 'string' ? { | ||
toSqlString: () => SqlString.escape(s).replace(/\\\\([_%])/g, '\\$1').replace(/\\'/g, '\'\'') | ||
} : s)) | ||
); | ||
console.log(queryString); | ||
const { QueryExecutionId } = await this.athena.startQueryExecutionAsync({ | ||
@@ -89,2 +94,2 @@ QueryString: queryString, | ||
module.exports = AthenaDriver; | ||
module.exports = AthenaDriver; |
@@ -5,3 +5,3 @@ { | ||
"author": "Statsbot, Inc.", | ||
"version": "0.10.28", | ||
"version": "0.10.30", | ||
"engines": { | ||
@@ -12,3 +12,3 @@ "node": ">=8.11.1" | ||
"dependencies": { | ||
"@cubejs-backend/query-orchestrator": "^0.10.28", | ||
"@cubejs-backend/query-orchestrator": "^0.10.30", | ||
"aws-sdk": "^2.403.0", | ||
@@ -18,3 +18,3 @@ "sqlstring": "^2.3.1" | ||
"license": "Apache-2.0", | ||
"gitHead": "3b428998843c30c35d9022e371da64911b434432" | ||
"gitHead": "4c835abe39cac254ea6e3ac82cc26523a9e85240" | ||
} |
18905
85
+ Addedpossible-typed-array-names@1.1.0(transitive)
- Removedpossible-typed-array-names@1.0.0(transitive)