I am populating EAN13 codes in a method and assigning them to a product_product item.
However, I would like to test in advance if value already exists for any other product.
How is tested in Odoo if there is any product_product with a given EAN13 value?
Or, as a more general question, how do you check in Odoo if there is any product with a certain value (say FOOBAR) in a given field?