Inconsistencies between the 2 different database properties forms

Wappler Version : v5.3.1
Operating System : macOS Monterey Version 12.6
Server Model: nodejs
Database Type: postgresql
Hosting Type: Wappler Local Server

Expected behavior

To be able to set dynamic values for database connection details using the Database Manager. And/Or to be able to Test the database connection via Workflows->Globals->Database Connections.

Actual behavior

I’m using ENV variables with my database connection details. In order to do this I need to input them via the form under Workflows->Globals->Database Connections. The reason for this is that the form under Database Manager->Database Connections doesn’t provide the symbol for using dynamic data.

Additionally, the form under Workflows->Globals->Database Connections doesn’t have a Test button, which the other form does.

Theoretically I could enter the ENV details via the Workflows form and then go to the Database Manager form to Test the connection. However, there doesn’t appear to be a way to edit the connection details from the Database Manager, and therefore I can’t bring up the form containing the Test button.

This is causing me quite a bit of grief at the moment, so any help, advice of fix would be very much appreciated.

How to reproduce

Create a database connection using the Database Manager and then create another under Workflows->Globals->Database Connections. Observe the difference in the forms.

Database Manager->Database Connections:

Workflows->Globals->Database Connections:

The form you show above that shows ‘Direct Database Connection’ (from Database Manager) is a static connection used by the Wappler UI to discover the tables and data of your database to allow query manager and other elements to build queries etc.

The Database Connections form (the one that allows dynamic data) is what is used by the site when running to query the database and can therefore use the ENV data from your server. The Wappler UI doesn’t necessarily have access to this dynamic data hence why the Test button doesn’t show

1 Like

Ok, so the Direct Database Connection grabs the schemas for which any dynamic Database Connections are expected to comply with.

@bpj Thanks for your response, I understand how it works now.

2 Likes