i have row like below Structure:
Product UOM Barcode_one Barcode_Two Barcode_three Barcode_four price
Orange unit 123 456 789 457 23
Orange dozen 378 210
orange pack 222 29437 200
apple unit 345 60
when i search the barcode with barcode like 378 it will display only one row ..
Orange dozen 378
i want to display all the 3 rows .. with any barcode ..
My XML
<search string="Search Product by Barcode">
<field name="name" string="Barcode"
filter_domain="['|','|','|',
('barcode_one','ilike',self),
('barcode_two','ilike',self),
('barcode_three', 'ilike', self),
('barcode_four', 'ilike', self),
]"/>
<field name="related_categ_id"/>
<field name="related_type"/>
<field name="related_group_id"/>
</search>
MY select Query like :
Select * from product_pricelist_item
where
barcode_one ilike '29437'
or barcode_two ilike '29437'
or barcode_three ilike '29437'
or barcode_four ilike '29437'
or product_tmpl_id in ( Select product_tmpl_id from
product_pricelist_item where
barcode_one ilike '29437'
or barcode_two ilike '29437'
or barcode_three ilike '29437'
or barcode_four ilike '29437')
How to resolve it ?