The following syntax works in Toad for Oracle 12.1
SELECT deptid,
XMLAGG (XMLELEMENT (E,lastname||'; ') ).EXTRACT ('//text()') AS "EMPS"
FROM
(SELECT deptid, lastname FROM emptest)
GROUP BY deptid;
However this same query does not work in Toad Data Point when connected to the same Oracle database. Instead the following error occurs:
ORA-00942: table or view does not exist