how to see multiple column values in new line Possible Duplicate:
  how to query multiple row data in single column in oracle?  




my table structure is given bellow

deptid  ename
------  ------
10  CLARK,KING,MILLER
20  ADAMS,FORD,JONES,SCOTT,SMITH


but i want the output sould be 
like

deptid  ename
----------------
10      CLARK,
        KING,
        MILLER
------------------
20      ADAMS,
        FORD,
        JONES,
        SCOTT,
        SMITH


please tell me how to do it in sql
select deptid, replace(ename, ',', ',\n') from table;


Try to use this query and it will gives you your expected result.