Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Error defining day LOV as function of month and year

Igor KortchnoïMay 6 2009 — edited May 8 2009
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
This post has been answered by ATD on May 6 2009
Jump to Answer

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Jun 5 2009
Added on May 6 2009
5 comments
324 views