How to get the count of records based on a certain criteria.If i need to get the number of recordsets having particular value in its field.
example-If i need to get number of records having a particular name in its name field.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
How to get the count of records based on a certain criteria.If i need to get the number of recordsets having particular value in its field.
example-If i need to get number of records having a particular name in its name field.
Hi,
To get the number of records satisfying the given criteria you can the search_count.
total_len = self.env['model_name'].search_count([('document_type', '=', 'entry')])
Thanks
Thanks
Good !!
Is this possible for qweb view?
Crie uma conta hoje mesmo para aproveitar os recursos exclusivos e interagir com nossa incrível comunidade!
Inscreva-se| Publicações relacionadas | Respostas | Visualizações | Atividade | |
|---|---|---|---|---|
|
How to install odoo 10 in ubuntu 20.04?
Resolvido
|
1
set. 23
|
3955 | ||
|
3
mai. 23
|
6543 | |||
|
7
abr. 23
|
50013 | |||
|
Barcode scanner from mobile
Resolvido
|
1
dez. 22
|
8611 | ||
|
How to set a domain for a field in XML?
Resolvido
|
4
dez. 23
|
27628 |
1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.