The tag has no wiki summary.

learn more… | top users | synonyms

1
vote
1answer
51 views

“No Loop” Constraint for hierarchical data in postgresql

I've got table like this in postgres: id primary key parent_id foreign key on id some data columns I need no a constrain which prevents cycles on the parent relations. There might be more tree in ...
-3
votes
1answer
113 views

MySql - Get all child categories until not exists

Based on this answer, can you please tell me what's wrong in the next code ? I'm trying to get all child categories. The example that I try it is: DELIMITER $$ DROP FUNCTION IF EXISTS ...
2
votes
0answers
87 views

Building a tree in Apache Derby 10.10

I know this question has been asked probably a million times, so please forgive me asking it again. I am not a DBA and have very little knowledge of SQL and Derby, but need some kind of a solution as ...
0
votes
0answers
49 views

MySQL: Hierarchical query to get the direct and indirect child

I am just trying to modify the code as in MySQL: Tree-Hierarchical query to get values inside single quotes and seems like the system hangs. Not sure where I am going wrong.. Here is the code. BEGIN ...
0
votes
0answers
39 views

How can I use PostgreSQL's partial sum tree index (if it even exists)? Do any databases allow for use of such an index?

GiST (Generalized Search Tree) indexing is an advanced system which brings together a wide array of different sorting and searching algorithms including B-tree, B+-tree, R-tree, partial sum trees, ...
0
votes
0answers
83 views

PostgreSQL: Store hierarchial data and return a recursive result with full path data

Background: I am considering whether to use LTREE or Recursive CTE with Materialized Path. For storing data, I am deciding between HSTORE or JSON. Objective: I need to store a hierarchial data. Each ...
0
votes
0answers
27 views

Proper tree NoSQL structure with focus on full-text searching

I developing an app with tree(folder-file) structure, on which I should perform full-text searches with MongoDB. I did a research on the best tree structure practices and found this great article, but ...
0
votes
0answers
139 views

How to represent group by in relational algebra

I have to plan a plan tree based on relational algebra.My question is that at some point I have a SORT ORDER BY the output of a join, so how do you represent group by in relational algebra.