Skip to content

Instantly share code, notes, and snippets.

@abhinavsharma
Created July 15, 2011 19:26
Show Gist options
  • Save abhinavsharma/1085362 to your computer and use it in GitHub Desktop.
Save abhinavsharma/1085362 to your computer and use it in GitHub Desktop.
Get all bookmarks inside folders
SELECT bm.folder_name, bm.folder_id, p.title as title, p.url as url FROM (SELECT f.title as folder_name, f.id as folder_id ,b.title, b.fk as place_id FROM (SELECT * FROM moz_bookmarks where type=2 AND (parent=2 OR parent=3)) f JOIN moz_bookmarks b ON f.id = b.parent) bm JOIN moz_places p ON p.id = bm.place_id
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment