Odoo Technical

Welcome!

This community is for professionals and enthusiasts of our products and services.
Share and discuss the best content and new marketing ideas, build your professional profile and become a better marketer together.

0

Why does the default search method in Odoo only return active records, and how can you modify the domain to include inactive records as well?

Avatar
harini_s

Why does the default search method in Odoo only return active records, and how can you modify the domain to include inactive records as well?

Avatar
Discard
1 Answer
0
Avatar
priyanka
Best Answer

In Odoo, the code partners = self.env['res.partner'].search([('any_integer_field', '=', value)]) is designed to search for "active" records only. 

If you require fetching inactive records using this domain, you can use ('active', 'in', [True,False])


Avatar
Discard