3
3
from databricks .sql .exc import *
4
4
5
5
# PEP 249 module globals
6
- apilevel = ' 2.0'
6
+ apilevel = " 2.0"
7
7
threadsafety = 1 # Threads may share the module, but not connections.
8
- paramstyle = ' pyformat' # Python extended format codes, e.g. ...WHERE name=%(name)s
8
+ paramstyle = " pyformat" # Python extended format codes, e.g. ...WHERE name=%(name)s
9
9
10
10
11
11
class DBAPITypeObject (object ):
@@ -19,12 +19,13 @@ def __repr__(self):
19
19
return "DBAPITypeObject({})" .format (self .values )
20
20
21
21
22
- STRING = DBAPITypeObject ('string' )
23
- BINARY = DBAPITypeObject ('binary' )
24
- NUMBER = DBAPITypeObject ('boolean' , 'tinyint' , 'smallint' , 'int' , 'bigint' , 'float' , 'double' ,
25
- 'decimal' )
26
- DATETIME = DBAPITypeObject ('timestamp' )
27
- DATE = DBAPITypeObject ('date' )
22
+ STRING = DBAPITypeObject ("string" )
23
+ BINARY = DBAPITypeObject ("binary" )
24
+ NUMBER = DBAPITypeObject (
25
+ "boolean" , "tinyint" , "smallint" , "int" , "bigint" , "float" , "double" , "decimal"
26
+ )
27
+ DATETIME = DBAPITypeObject ("timestamp" )
28
+ DATE = DBAPITypeObject ("date" )
28
29
ROWID = DBAPITypeObject ()
29
30
30
31
__version__ = "2.0.2"
@@ -45,4 +46,5 @@ def TimestampFromTicks(ticks):
45
46
46
47
def connect (server_hostname , http_path , access_token , ** kwargs ):
47
48
from .client import Connection
49
+
48
50
return Connection (server_hostname , http_path , access_token , ** kwargs )
0 commit comments