Reputation: 71
I have two collections where one collection is referencing another. Below is my structure:
CURRENCY_PAIR
CURRENCY_PAIR_LIMIT
How can i query both collections such that when i get a currency pair, it is equal to the Limit_Buy_Price_Threshhold
field that was added to the db with.
Upvotes: 0
Views: 1139
Reputation: 4126
As provided on this thread, Firestore does not have a concept of server-side JOIN which is very near to what you want to achieve when you mentioned that you wanted to query both collections.
What I could think of is that you could remodel your database in a way that you can perform collection group queries. It works by putting CURRENCY_PAIR_LIMIT
as a subcollection to the document in CURRENCY_PAIR
.
Upvotes: 1