FirebirdSQL / python3-driver

Firebird driver for Python that uses new Firebird API
https://www.firebirdsql.org/en/devel-python-driver/
MIT License
26 stars 10 forks source link

Multiple Firebird instances on same machine #3

Closed eko234 closed 2 years ago

eko234 commented 3 years ago

I'm developing a web service where I need to connect to different databases depending on the request, said databases are in different firebird versions and are listening on different ports, the thing is I can't seem to find a way to even connect to one because I got an error saying:

FileNotFoundError: Could not find module 'fbclient.dll' (or one of its dependencies). Try using the full path with constructor syntax.

I'm using windows and when I run this function before the connection:

load_api("C:/Users/luis/Liquidador_IYC/fbclient.dll")

I get a [WinError193] 1% saying that this is not a valid win32 application.

So the question is, is there a recommended way to handle multiple firebird instances?, and can I connect using something like "127.0.0.1:por>/db-path" dinamically?.

pcisar commented 2 years ago

First, this is an support issue. Most likely you are using 32-bit application (Python) with 64-bit Firebird. You should either use 64-bit Python, or 32-bit Firebird, or at least install 32-bit Firebird client.