Managing database data
Last updated
Was this helpful?
Last updated
Was this helpful?
Now that you've added your Firebase database as the data source, you can start managing its data. Here, you'll learn how to perform CRUD operations with and .
of the JavaScript Code type and add the following code:
Click Execute action and check the Result tab - the data should be there.
Click Execute action and check the Result tab - the new record should be created.
Updates can be executed using two methods - set()
and update()
. Below you'll find an example of both methods.
set()
Please note that set()
can overwrite your data, while update()
only updates the required fields.
update()
Click Execute action and check the Result tab - the requested records should be updated with the new values.
Click Execute action and check the Result tab - the specific record should be removed.
Click Execute action and check the Result tab - your collection data should be displayed.
Click Execute action and check the Result tab - document data should be displayed.
Click Execute action and check the Result tab - the new record should be there.
Click Execute action and check the Result tab - the record should be deleted.
Updates can be executed using two methods - set()
and update()
. The difference between them is that set()
will overwrite the whole document while update()
will update only specific fields that need to be updated.
Below you'll find an example of both methods.
set()
update()
Click Execute action and check the Result tab - the requested records should be updated with the new values.
of the JavaScript Code type and add the following code:
of the JavaScript Code type and add the following code depending on the selected method:
of the JavaScript Code type and add the following code:
All other operations with the Realtime Database data like Filter, Order, etc. can be done via the Firestore API. You can find the API reference .
You can also check out more useful articles on how to further manage your data in UI Bakery
of the JavaScript Code type and add the following code to load your Firestore collection:
of the JavaScript Code type and add the following code to fetch data about a specific document:
of the JavaScript Code type and add the following code:
of the JavaScript Code type and add the following code:
of the JavaScript Code type and add the following code depending on the selected method:
All other operations with the Firestore collections like Filter, Order, etc. can be done via the Firestore API. You can find the API reference .
You can also check out more useful articles on how to further manage your data in UI Bakery