Getting DB entry by primary key

I’m making my first app and still learning. I can’t figure out how to access database entries by the value of a field. Specifically, I am trying to display a random entry from the database. I assigned each entry a unique integer from 1 to 20 in a column called “primary key”; then in my workflow I (1) generate a random number using the random number plugin, then (2) get stuck. The picker lets me access the random number, but I can’t figure out how to uniquely select the entry so that primary key = the random number from step 1. Any help would be appreciated.

Hello and welcome.

You can get a random entry from the database by using the :random Item from the built-in functions after the Search. Just click in the expression builder.

If you really need to use the random numbers, the you can add a constraint to the search primary key = picker’s value.

After that you need to add : firstitem to tell Bubble that this is ONE row coming back.