2

Do we have same as WHEREIN of MySQL in Firestore? If we don't have such option in Firestore, Then, How to handle it with NodeJS?

I hope I can get my answer soon.

1 Answers1

1

Firestore uses NoSQL (non-relational) instead of SQL.

You can fetch data from firestore using Node.js as specific in this doc.

There is currently no "IN" operator in firestore, so the only way to handle this is using forEach.

To understand more about JSON format and how to handle it in Node.js, you can read this.

Tien Liang
  • 245
  • 1
  • 3
  • If we have array of documents id, then how to get those specified documents? Without foreach. – Mohammad Ibrahim hussaini Apr 02 '18 at 06:24
  • There is currently no "IN" operator in firestore. But you can referece this [link](https://stackoverflow.com/questions/46721517/google-firestore-how-to-get-document-by-multiple-ids-in-one-round-trip) – Tien Liang Apr 02 '18 at 06:36
  • 1
    array contains operator added: https://firebase.google.com/support/release-notes/js – Adarsh Aug 09 '18 at 03:51