0

I want to get all the jobs that Grade value New/Near New inside the job. job->container->grade Equal to New/Near New.

enter image description here

3
  • Have you checked? Firestore - Nested query Commented Aug 24, 2021 at 7:41
  • What programming language are you using? Please respond with @AlexMamo Commented Aug 24, 2021 at 7:42
  • @AlexMamo i am using react JS Commented Aug 24, 2021 at 7:51

1 Answer 1

1

To get all jobs with a grade value of New/Near New, you can use a query like this:

// Create a reference to the jobs collection
var collectionRef = db.collection("jobs");

// Create a query against the collection.
var query = collectionRef.where("container.grade", "==", "New/Near New");

And then you execute the query as also shown in the docs.

Sign up to request clarification or add additional context in comments.

1 Comment

You saved me @Frank . I also want to know about how to set multiple filters inside the where clause programmatically or dynamically. I am using react js i want to set multiple where clauses depend on user input. eg: 1st case User want to filter Status and Created time same time, 2nd case User want to filter status, Created time, Grade same time. How to set Filters depend on user selection>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.