You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
mahuntington 5d67fc7d02
Update 'README.md'
3 years ago
templates details for adding children 3 years ago
.gitignore gitignore 3 years ago
README.md Update 'README.md' 3 years ago
server.py cleanup 3 years ago

README.md

WITH RECURSIVE parent (id, title, description, path) AS
(
  SELECT id, title, description, title as path
    FROM items
    WHERE parent_id IS NULL
  UNION ALL
  SELECT items.id, items.title, items.description, CONCAT(parent.path, ' > ', items.title)
    FROM parent JOIN items
      ON parent.id = items.parent_id
)
SELECT * FROM parent WHERE id = 38;