QUERY CRITERIA MANAGER
Hi There,
I am in a middle of developing a form in which there is a need of CRITERIAS to fetch records accordingly.
So I have a form in which i have three blocks.
1. (QUERY_BLK) contains text items (non database) and block is also non-database.
2. (HEADER_BLK) contains tabular records (MASTER block)
3. (DETAIL_BLK) contains tabular records (DETAIL block) ...
After that I have written conditions like this in BLOCK where field (design time)
(AMOUNT=:QUERY_BLOCK.AMOUNT OR :QUERY_BLOCK.AMOUNT IS NULL) AND (V_TYPE=:QUERY_BLOCK.LST_VTYPES OR :QUERY_BLOCK.LST_VTYPES IS NULL) AND (V_DATE = :QUERY_BLOCK.VDATE OR :QUERY_BLOCK.VDATE IS NULL)
so when user enters criteria's in the QUERY_BLK fields he/she presses RUN_QUERY button which triggers the following code.
GO_BLOCK('HEADER');
EXECUTE_QUERY;
Ok now come to my problem...I have several fields where range is required like amount and date has different variations for example ...
amount < 5000
amount > 5000
amount between 40000 and 50000 ...etc etc...
date > 26-05-07
date < 25-06-05
date between 24-06-07 and 29-06-07
Keep this in mind that my QUERY BLOCK is non-database and thats why I cant put operators in the field like we do in ENTER-QUERY mode. Is there any alternate that I can use the text items (non database) and use operators alongwith the current way of doing query? or something else
So please guide me the best possible way to achieve this otherwise I need to do lots of effort to put range fields ..like FROM TO ...or between etc etc...which i dont want to do...plz guide