-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
I am attempting to use this to connect to a SQL Anywhere 17 database, but unfortunately I can't complete the initial test upon installing the application. What am I doing wrong? Here is the traceback:
`InterfaceError Traceback (most recent call last)
Cell In[3], line 2
1 import sqlanydb
----> 2 conn = sqlanydb.connect(uid='dba', pwd='sql', eng='demo', dbn='demo' )
3 curs = conn.cursor()
4 curs.execute("select 'Hello, world!'")
File /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sqlanydb.py:566, in connect(*args, **kwargs)
564 def connect(*args, **kwargs):
565 """Constructor for creating a connection to a database."""
--> 566 return Connection(args, kwargs)
File /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sqlanydb.py:582, in Connection.__init__(self, args, kwargs, parent)
578 if parent == None:
579
580 # cache the Root() object so we don't load it every time
581 if Connection.cls_parent == None:
--> 582 parent = Connection.cls_parent = Root("PYTHON")
583 else:
584 parent = Connection.cls_parent
File /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sqlanydb.py:496, in Root.__init__(self, name)
493 def __init__(self, name):
495 lg.debug("Attempting to load dbcapi library")
--> 496 self.api = load_library(os.getenv( 'SQLANY_API_DLL', None ), 'dbcapi.dll', 'libdbcapi_r.so',
497 'libdbcapi_r.dylib')
498 ver = c_uint(0)
499 try:
File /Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/sqlanydb.py:488, in load_library(*names)
486 except OSError as ose:
487 continue
--> 488 raise InterfaceError("Could not load dbcapi. Tried: " + ','.join(map(str, names)))
InterfaceError: ('Could not load dbcapi. Tried: /Applications/SQLAnywhere17/System/lib64/libdbcapi_r.dylib,dbcapi.dll,libdbcapi_r.so,libdbcapi_r.dylib', 0)`
Metadata
Metadata
Assignees
Labels
No labels