3 ms·
Since way back when the tablefunc contrib module had a connectby() function, but it has some limitations being a C function. The better way is to use WITH RECU
by einhverfr 14y ago
Since way back when the tablefunc contrib module had a connectby() function, but it has some limitations being a C function.
The better way is to use WITH RECURSIVE CTE's. See http://ledgersmbdev.blogspot.com/2012/07/ctes-and-ledgersmb.html http://ledgersmbdev.blogspot.com/2012/07/ctes-and-ledgersmb.... for how we use them in LedgerSMB for hierarchical data.