title: Recursive function to select a hierarchy for a table without using connect by. PL SQL
body: <p>I need to select all the tables that have references to my table in a recursive manner.</p>
  
  <p>So, lets say I need to perform this task for the <strong>book_author</strong> table.
  A query like this one:</p>
  
  <pre><code>select distinct sys_connect_by_path(a.table_name, '/'), level
    from user_constraints a
    join user_constraints b
      on a.table_name = b.table_name
   start with a.table_name = 'BOOK_AUTHOR'
  connect by prior a.r_constraint_name = b.constraint_name
  </code></pre>
  
  <p>GIves me this result</p>
  
  <pre><code>/BOOK_AUTHOR/D_BOOK/JOBS/CITY/COUNTRY/REGIONS   6
  /BOOK_AUTHOR/D_BOOK/JOBS/CITY/COUNTRY   5
  /BOOK_AUTHOR/D_BOOK/JOBS/CITY   4
  /BOOK_AUTHOR/D_BOOK/D_STYLE 3
  /BOOK_AUTHOR/D_BOOK/JOBS    3
  /BOOK_AUTHOR/D_AUTHOR   2
  /BOOK_AUTHOR/D_BOOK 2
  /BOOK_AUTHOR    1
  </code></pre>
  
  <p>, which is pretty much what i need.</p>
  
  <p>Could you please help me to get the same result <strong>without</strong> using  connect by but with the help of the <strong>recursive function</strong> calls?</p>
  
  <p><em>P.S. Dont be confused with the mystical connection of tables books, jobs, countries, etc. - I've been playing with the foreign keys in those tables for quite a time - as I wanted to make my hierarchy really deeeeeep</em></p>