File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -4,11 +4,22 @@ const { text } = require('stream/consumers')
44
55const hdb = require ( 'hdb' )
66const iconv = require ( 'iconv-lite' )
7+ const cds = require ( '@sap/cds' )
78
89const { driver, prom, handleLevel } = require ( './base' )
910const { resultSetStream } = require ( './stream' )
1011const { wrap_client } = require ( './dynatrace' )
1112
13+ if ( cds . env . features . sql_simple_queries === 3 ) {
14+ // Make hdb return true / false
15+ const Reader = require ( 'hdb/lib/protocol/Reader.js' )
16+ Reader . prototype . _readTinyInt = Reader . prototype . readTinyInt
17+ Reader . prototype . readTinyInt = function ( ) {
18+ const ret = this . _readTinyInt ( )
19+ return ret == null ? ret : ! ! ret
20+ }
21+ }
22+
1223const credentialMappings = [
1324 { old : 'certificate' , new : 'ca' } ,
1425 { old : 'encrypt' , new : 'useTLS' } ,
@@ -24,7 +35,6 @@ class HDBDriver extends driver {
2435 constructor ( creds ) {
2536 creds = {
2637 fetchSize : 1 << 16 , // V8 default memory page size
27- dataFormatSupport : 7 , // with 7 hana supports booleans
2838 ...creds ,
2939 }
3040
You can’t perform that action at this time.
0 commit comments