0

Here is scenario:

   id  parent_id  search
   1   null       hello
   2   1          hello/something
   3   1          hello/new
   4   null       new
   5   4          new/hello

Then I got via querybuilder and searching "hello" to this results:

   1   null       hello
   2   1          hello/something
   3   1          hello/new
   5   4          new/hello
   5   4          new/hello

How to build nested tree via querybuilder if I want only get all elements inside childs, include "hello/something" ?

How to build up using symfony to array?

Marin Sagovac
  • 3,932
  • 5
  • 23
  • 53

1 Answers1

0

Assuming you're using Doctrine, check out the tree extension in DoctrineExtensions

Dan Blows
  • 20,846
  • 10
  • 65
  • 96