@@ -2,24 +2,13 @@ const { Readable, Stream, promises: { pipeline } } = require('stream')
22const { StringDecoder } = require ( 'string_decoder' )
33const { text } = require ( 'stream/consumers' )
44
5- const cds = require ( '@sap/cds' )
65const hdb = require ( 'hdb' )
76const iconv = require ( 'iconv-lite' )
87
98const { driver, prom, handleLevel } = require ( './base' )
109const { resultSetStream } = require ( './stream' )
1110const { wrap_client } = require ( './dynatrace' )
1211
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-
2312const credentialMappings = [
2413 { old : 'certificate' , new : 'ca' } ,
2514 { old : 'encrypt' , new : 'useTLS' } ,
@@ -35,6 +24,7 @@ class HDBDriver extends driver {
3524 constructor ( creds ) {
3625 creds = {
3726 fetchSize : 1 << 16 , // V8 default memory page size
27+ dataFormatSupport : 7 , // with 7 hana supports booleans
3828 ...creds ,
3929 }
4030
0 commit comments