Hi all,
As we all know we can perform operations such as co_EQUAL, co_GRATER_EQUAL,co_GRATER_THAN, co_LESS_EQUAL, co_LESS_THAN, co_NONE, and as well as co_NOT_EQUAL. Can any one help me what should i do to perform an operation similar to the following query using the Conditions object
"Select DocNum from OCRD where DocEntry IN (1,2,4)"
Thanks
John
In order to emulate an 'IN' with the coditions object, you will need to string together condition objects in the Conditions collection with the Relationship property set to cr_OR.
Like this:
(
(Docentry CO_equal 1)
OR
(Docentry CO_EQUAL 2)
OR
(Docentry CO_EQUAL 4)
)
Hi John,
The in clause works in the query generator although is not available in the conditions options. Edit the select and try this for example:
Select DocEntry from ORDR where DocNum IN (1,2,4)
Works fine for me.
Regards,
Ibai Peñ
Add a comment