Error in Query
Posted: Sun Sep 23, 2007 5:23 am
I am getting one error in the following query when using in Forms.The error is "Encounted Symbol "("When expecting one of the Following: ,from ).
But the same query is working in Sql Plus.Please Help
Thanks
Ax
Query
--------
select att_empcode,
max(decode(column#,1,att_time)),
max(decode(column#,2,att_time)),
max(decode(column#,3,att_time)),
max(decode(column#,4,att_time))
into :ATT_EMPCODE,:Att_Time,:Outime1,:Intime2,:Outtime2
from (select att_empcode,att_time,row_number()
over (partition by att_empcode order by att_time) as column#
from xxatn_final_att
where att_date = '12/09/07')
group by att_empcode order by 1
But the same query is working in Sql Plus.Please Help
Thanks
Ax
Query
--------
select att_empcode,
max(decode(column#,1,att_time)),
max(decode(column#,2,att_time)),
max(decode(column#,3,att_time)),
max(decode(column#,4,att_time))
into :ATT_EMPCODE,:Att_Time,:Outime1,:Intime2,:Outtime2
from (select att_empcode,att_time,row_number()
over (partition by att_empcode order by att_time) as column#
from xxatn_final_att
where att_date = '12/09/07')
group by att_empcode order by 1