What is the specialty of the "left" and "right" fields in jstree jquery plugin?

I am using jquery plugin jstree to create a tree.

When I execute this plugin database file, this db has 2 fields "left" and "right", so I do not know what these fields are used for what? If I set the value of these fields to 0, the tree will show only the root note, child notes will not appear.

Please explain to me how the use of the "left" and "right" fields in jsTree :) Thanks!

+3
source share
1 answer

It is called a Nested Set Model and is used to easily retrieve the whole tree with a single db request.

+5
source

All Articles