conversion problem [message #217452] |
Fri, 02 February 2007 05:32 |
|
hi all,
i have a problem.
i have a 'text-box' with name 'txt' in a control-block of a form.ok
and i have a table in back-end .
SQL> select ldr_no ,yr from leader_info;
LDR_NO YR
--------------- ---------
1066 01-DEC-06
1085 01-DEC-06
1063 01-DEC-06
327 01-DEC-06
007 01-DEC-07
1234 01-DEC-07
6 rows selected.
now problem is that , i want to insert only 2006 in the text-box named txt in front-end.
and want to extract the LDR_NO ,yr from table where date is same as the given number in text box ,just like
only these willbe selected .
LDR_NO YR
--------------- ---------
1066 01-DEC-06
1085 01-DEC-06
1063 01-DEC-06
327 01-DEC-06
if i insert 2007 then i want to get .
LDR_NO YR
--------------- ---------
007 01-DEC-07
1234 01-DEC-07
i use to_Date(txt,'rrrr') function in the select command but it is not generatin the desire result.
i think it is a simple problem but now i m too much tired.
so help me now how i do this possible.
regards.
|
|
|
|
|
|
|