I'm trying to work with Query API to get matched results set from Vtiger.
This API works fine with normal queries (without multiple AND/ OR conditions) like:
working_query = SELECT * FROM Leads WHERE id = 10x2482688 AND designation = 'SalesMan' order by createdtime LIMIT 1;
But we want to get results using nested AND/OR and those will contain parentheses. ")"
and we are getting errors like 'QUERY_SYNTAX_ERROR', Syntax Error on line 1: token '(' Unexpected
Not_working_query = SELECT * FROM Leads WHERE id = 10x2482688 AND (email = 'test@yahoo.com' OR designation = 'SalesMan') order by createdtime LIMIT 1;
Any ideas on how we can resolve this?