Hi: I'm having trouble with this query...
select sr.sqf_id, sr.status, fse.perl_sub_name, fse.end_datetime from sqf_runs sr, (select perl_sub_name, end_datetime from flow_step_events_view where sqf_id = sr.sqf_id order by 2 limit 1) fse where sr.userid='foo'; ERROR: invalid reference to FROM-clause entry for table "sr" LINE 4: ...atetime from flow_step_events_view where sqf_id = sr.sqf_id ... ^ HINT: There is an entry for table "sr", but it cannot be referenced from this part of the query. If this is indeed a foul, how can I accomplish the same thing ? Thanks in Advance !