SELECT lpad('-', 3*(level-1)) || pagename FROM tablename START WITH under=0 CONNECT BY PRIOR pageid = undef;