I am using the below query where minDaysToDeparture
and maxDaysToDeparture
are string but I have to put in the where
block with comparison operators.
I have tried the below queries (not working):
SELECT *
FROM Rules
WHERE (
AND ( minDaysToDeparture<='8' )
AND ( maxDaysToDeparture>='8' )
AND status = '1' )
SELECT *
FROM Rules
WHERE (
AND ( '5'<='8' )
AND ( '10'>='8' )
AND status = '1' )
The below query works, but somehow I cannot change type of '8' it has to remain string. But if there is any toNumber method then I can use it without any issue.
SELECT *
FROM Rules
WHERE (
AND ( 5<=8 )
AND ( 10>=8 )
AND status = '1' )
Looking forward to your help.
Thanks!