Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

528
Views
TypeORM find where clause, how to add where in multiple parameter
this.sampleRepo.find (
            {
                where: {
                    id: In ["1","7","13"]

                  }
                order: {
                    id: "DESC"
                },
                select: ['id','group']
                
                
            }

    );

how to add where clause here so that i can find records only where user id is one or 7 or 13.

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

You've missed round brackets and probably missed importing the In operator:

import { In } from 'typeorm';

...
...
...

this.sampleRepo.find({
    where: {
      id: In(['1', '7', '13'])
    },
    order: {
      id: 'DESC'
    },
    select: ['id', 'group']
});
over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!