Querying a Data Base?

So I’ve used the SQL DATABASE CONNECTOR API and connected my database, here’s the issue when I display the data on my page it displays every entry. Is there a way to filter these dynamically using current user information from bubble.

Example:

I want to grab a users “Bank” data from my SQL server so I set up a query with a parameter to look for an identifier. This identifier is both in my SQL database and Bubbles Built-in Database, the user should have the same exact values in both databases for it to pull that data array.

Above I’ve established the parameter in the API connector, below I’ve connected the API to a text element in bubble. However, for some reason, it does not wish to filter the results base off of the identifier parameter or any parameter at all.

Does anyone have any thoughts on how to fix this issue, @emmanuel is this an issue with the API it self?

You need to put placeholders into the query so it knows where to bind the parameters. MSSQL can use named parameters …

SELECT TOP 200 * FROM users WHERE identifier = @identifier

or

SELECT * FROM users WHERE identifier = @identifier LIMIT 200

Hmmm going by your other topic you are using MySQL?

In this case, use ? as a parameter placeholder …

SELECT * FROM users WHERE identifier = ? LIMIT 200

Yes it is MySQL and I tried that well both and niether worked saldy

If you send me a PM with a link to an open app editor, I’ll help you diagnose further.

Or you can raise a bug with Bubble, I’m not sure if this is in their scope though.

Hi, I’m curious if you ever got this to work and how did you do it.
I would appreciate your input as well, @mishav
Thanks in advance.