Base connection to firebird with username / role

Hi,

my setup consists of writer forms (ubuntu, windows, mac os) as front end, and firebird (docker container running on a synology / DSM server) as the data base.

As we need flexibility with database permissions, I have started using roles that I then assign to users for avoiding any burden and errors.

I however discovered that roles to user assignment (after firebird 3 …my guess) only works if identification specifies the role as well as the user name. This is possible for example with isql, flamerobin and so on.

Anyone knows if this is possible when registering or logging into the database to LO / Base ? If not I am probably forced into writing a specific login macro, something I would like to avoid.

Any help is appreciated.

server ? or embedded ?

see some gory details here : Base - connecting to Firebird database (w/o ODBC) - #5 by mariosv

firebird is running on a (docker) server …

I will look if JDBC allows a role parameter like user or password …

For JDBC try something like this:

jdbc:firebirdsql:oo://localhost/libretest.fdb?charSet=UTF-8

Driver will be org.firebirdsql.jdbc.FBDriver from https://www.firebirdsql.org/en/jdbc-driver/

Thank you guys : I will try JDBC. For the time being I use sdbc.

BTW which driver can be considered the best in terms of performance and functionality ? I remember that Ratslinger (akalo-guro) was recommending JDBC.

Gave it a try but it fails


image

Test class succeed but test connection fails …

Maybe:
jdbc
instead of
dbc
in the jdbc connection

Without any such prefix. Protocol jdbc: is already set as indicated by the label in front of the input box.

1 Like

Villeroy, many thanks : I did non notice the jdbc: prefix … IT WORKS NOW :slight_smile:

Stopped working
Test Class passed
Test Connection
Unable to complete network request to host “oo”. [SQLState:08006, ISC error code:335544721]

jdbc:firebirdsql:oo://192.168.1.37/var/lib/firebird/data/firebird.fdb?charSet=UTF-8
org.firebirdsql.jdbc.FBDriver

The connection strig should be firebirdsql:oo:192.168.1.37:/var/lib/firebird/data/firebird.fdb?roleName=ROLE_NAME&charSet=UTF-8 (the jdbc part is already written)

What is the oo:? And the colon behind the IP is one too many unless you add a port number.

a wild recommendation :face_with_thermometer:

pointing to a decent documentation wouldn’t hurt :wink: