0

i have come across oracle connect by queries, but is there an alternate for MySQL? My intention is to develop an app where the hierarchical query works with multiple databases. Or are there any hibernate alternatives?

  • 2
    No it doesn't. See this question and anwser: http://stackoverflow.com/questions/11806528/does-mysql-have-the-equivalent-of-oracles-analytic-functions – davek May 31 '13 at 12:49
  • To work with "multiple" databases you would need to use "recursive common table expressions" which are supported by all modern DBMS - just not MySQL (`connect by` is an Oracle specific feature) –  May 31 '13 at 13:30

1 Answers1

0

or you can design your database to be easier to work with hierarchical for multiple database such as Nested set model or Closure tables model

invisal
  • 11,075
  • 4
  • 33
  • 54