-- SQL to get Class Data see also TCSQGetClassdata.pptx
SELECT x.pname ClassNamet,
   pa.pname AttrNameinTcClass,
   pc.PTNAME AttrDatainTbl,
   pa.PDBNAME AttrDataInTblColume
FROM
  (SELECT level sortx,
    connect_by_root(pname) classes,
    pname
   FROM infodba.ppom_class
    -- pname ClassName
    WHERE pname LIKE 'Dataset%' or pname like 'SEP_Des%'
    CONNECT BY nocycle prior pname = psuperclass
  ORDER BY level DESC
  ) x,
  infodba.ppom_attribute pa,
  infodba.ppom_class pc
WHERE x.classes = pc.pname
AND pc.puid     = pa.rdefining_classu
 -- Name of Attribut in TCClass
AND pa.pname like 's4_produc%';
