Services Plugins FAQs

Airbnb clone course: Need help with generating random string to database


I am working on the airbnb course and I cannot seem to figure out how to get the random string that is generated on the page and then getting that random string onto the database.

I have followed the directions on the bubble forum

As well as searching through the bubble forums for alternatives and also trying different ways to get a random string to the database to no avail.

I am able to generate a random string on the new rooms page, but how do I get that random string onto the database?

I generated a random string by adding an input on the page, then for initial content > insert dynamic data > calculate random string, type: generate random string, length of characters: 6


In the workflow, when the add button listing is clicked > create a new listing > ID= random string’s value

random’s string’s value becomes an error


And this is what is shown on the database: ID is 6 instead of YYJUXX that appears on the page.


Hi @jemisoul we’ll check this out and try to help you asap.

Hi there, @jemisoul

If I understood your request correctly, you can simply calculate the formula for generated random string directly to database when creating new listing with a workflow?

I mean you’re trying to create a random string and write it database right? Why do you need an input for that?
If you want to write the input’s value in your case (YYJUXX) to DB simply the ID field would be equal to input’s value.

ZQ Team.

Yes, that’s exactly what I want to do. Thank you. It works!
I was trying to get “ID= random string’s value” but an error message kept popping up so I was stuck in that mode of thinking and not realizing that there is simple solution.
Thank you for easy explanation!

1 Like