请教sql问题:ORA-00918: 未明确定义列
以下是sql内容,不知道哪儿错了。
select t.meta_task_result_id,
st.scheduler_name,
tt.task_name,
rt.resource_name,
upper(mtt.app_name),
mtt.tem_name,
mtt.tem_name,
t.instance,
mtt.descp,
case
when length(t.value) > 20 then
substr(t.value, 1, 20) || '...'
else
t.value
end,
mtt.UNIT,
T.META_TASK_STATE,
t.alarm,
T.ADVICE,
to_char(get_date_from_millisecond(t.time), 'YYYY-mm-dd HH24:mi:ss'),
t.alarm_info,
T.OPINION,
T.VALUE_CHECK,
t.meta_task_id,
st.minutes || ';' || st.hours as cyc,
mtt.value_type,
st.scheduler_id,
mtt.meta_task_id
from day_meta_task_result t,
scheduler_table st,
task_table tt,
meta_task_table mtt,
(select r1.resource_id,
decode(r2.value, null, r1.resource_name, r2.value) resource_name
from resource_table r1
left join resource_info_table r2
on (r1.resource_id = r2.resource_id and r2.ukey = 'test_key_1')) rt
where t.scheduler_id = '8aca818c312760f001312d18fdea0239'
and st.scheduler_id = '8aca818c312760f001312d18fdea0239'
and t.scheduler_id = st.scheduler_id
and st.task_id = tt.task_id
and t.meta_task_id = mtt.meta_task_id
and mtt.resource_id = rt.resource_id
and t.META_TASK_STATE = 0
and t.time = 1330880340117
order by rt.resource_name, mtt.tem_name