I need to perform synchronous query for my data , how to do that in firebase? I can find method with block which is asynchronous call. Please guid me.
Asked
Active
Viewed 5,034 times
2
-
Maybe if you could explain why a synchronous call is needed we could better help you. – Jay Mar 28 '16 at 17:43
1 Answers
4
Firebase is a cloud-hosted database. This means that to get data from the database requires establishing (or sending data) over the network. For this reason there is no method to synchronously load data from Firebase.
If you feel like working around this, have a look at this question: Force asynchrounous Firebase query to execute synchronously?. But I highly recommend that you embrace the asynchronous nature of using Firebase. Your users will be grateful if you do.

Community
- 1
- 1

Frank van Puffelen
- 565,676
- 79
- 828
- 807