Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
20052 Weergaven

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.

Avatar
Annuleer
Beste antwoord

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

Avatar
Annuleer
Auteur

Thanks

Is this possible for qweb view?

Gerelateerde posts Antwoorden Weergaven Activiteit
1
sep. 23
2927
3
mei 23
5499
7
apr. 23
48846
1
dec. 22
7740
4
dec. 23
26405