Error defining day LOV as function of month and year
Select '1' day_aff, '01' val from dual union
...
Select '29' , '29' from dual where '29' <= to_char(last_day(to_date('01.' || '02' || '.' || '2008', 'dd.mm.yyyy')), 'dd') union
Select '30' , '30' from dual where '30' <= to_char(last_day(to_date('01.' || '02' || '.' || '2008', 'dd.mm.yyyy')), 'dd') union
Select '31' , '31' from dual where '31' <= to_char(last_day(to_date('01.' || '02' || '.' || '2008', 'dd.mm.yyyy')), 'dd')
order by 2
That works OK.
If I replace '02' by :P10_MONTH, &P10_MONTH. or v('P10_MONTH') and 2008 by :P10_YEAR, &P10_YEAR. or v('P10_YEAR') , I get the following error on LOV creation (in shared components or in item's LOV section):
LOV query is invalid, a display and a return value are needed, the column names need to be different. If your query contains an in-line query, the first FROM clause in the SQL statement must not belong to the in-line query.
Any workaround?
Igor