{
  "attachments": [],
  "comments_archived": true,
  "date": "2005-06-28T15:53:35.000Z",
  "layout": "post",
  "title": "Safari RSS databases in Mac OS X Tiger - or Monkeys and Ninjas and Pirates and Robots, oh my!",
  "wordpress_id": 661,
  "wordpress_slug": "safarirssdb",
  "wordpress_url": "http://www.decafbad.com/blog/?p=661",
  "year": "2005",
  "month": "06",
  "day": "28",
  "isDir": false,
  "slug": "safarirssdb",
  "type": "entry",
  "postName": "2005-06-28-safarirssdb",
  "html": "<p>Hey, what do you know?  The database used by <code>Syndication.framework</code> on OS X is accessible with <a href=\"http://www.sqlite.org/version3.html\">SQLite 3</a>, assumedly by virtue of <a href=\"http://developer.apple.com/macosx/coredata.html\">Core Data</a>.  Check out this barely presentable capture of what I just did in a shell window:</p>\n<pre style=\"font-size: 0.75em; overflow: auto\">[11:34:49] deusx@Caffeina2:~/Library/Syndication$ sqlite3 Database3 \nSQLite version 3.0.8\nEnter \".help\" for instructions\nsqlite&gt; .tables\n\nArticles  Sources \n\nsqlite&gt; .schema Articles\n\nCREATE TABLE Articles (id INTEGER PRIMARY KEY,\nsource_id INTEGER,author TEXT,title TEXT,contentType INT(1),\ncontents TEXT,excerpt TEXT,GUID TEXT,permalink TEXT,iconURL TEXT,\ncategories TEXT,date DATETIME,dateReceived DATETIME,unread INT(1),\nflagged INT(1),collapsed INT(1),noComments INT(1));\nCREATE INDEX ArticleCurrents ON Articles (noComments);\nCREATE INDEX ArticleDates ON Articles (date);\nCREATE INDEX ArticleDatesRcvd ON Articles (dateReceived);\nCREATE INDEX ArticleSources ON Articles (source_id);\nCREATE INDEX ArticleUnreads ON Articles (unread);\n\nsqlite&gt; .schema Sources\n\nCREATE TABLE Sources (id INTEGER PRIMARY KEY,URL TEXT,\nsubscribed INT(1),title TEXT,iconURL TEXT,date INT,lastCheck INT,\nlastUpdate INT,slider INT(1),description TEXT,homePage TEXT,\ntimespan INT(1),sort INT(1),HTTPdate VARCHAR,feedHash VARCHAR(40),\nFOAFURL TEXT,protocol VARCHAR,lastError VARCHAR,maxDays INT(2),\nmaxArticles INT(2),x_monkey TEXT,x_ninja TEXT,x_pirate TEXT,\nx_robot TEXT);\n\nsqlite&gt; select * from Sources;\n\nid|URL|subscribed|title|iconURL|date|lastCheck|lastUpdate|slider|description|homePage|timespan|sort|HTTPdate|feedHash|FOAFURL|protocol|lastError|maxDays|maxArticles|x_monkey|x_ninja|x_pirate|x_robot\n1|http://www.apple.com/main/rss/hotnews/hotnews.rss|1|Apple Hot News||141617700|141648125|141648128|||http://www.apple.com/hotnews/|||Tue, 28 Jun 2005 02:15:00 GMT|150fdf111cd223367f5c0cb8d28c65ec2a4ec195||RSS|||||||\n2|http://ax.phobos.apple.com.edgesuite.net/WebObjects/MZStore.woa/wpa/MRSS/newreleases/limit=25/rss.xml|1|iTunes 25 New Releases|/images/rss/badge.gif|141577349|141648124|141648126|||http://phobos.apple.com/WebObjects/MZStore.woa/wa/com.apple.jingle.app.store.DirectAction/viewNewReleases?pageType=newReleases&amp;id=1|||Mon, 27 Jun 2005 18:02:29 GMT|8a2c02423581414b223f4533f0bf89211e1aa6c7||RSS|||||||\n\n...\n\nsqlite&gt; select * from Articles;\n\nid|source_id|author|title|contentType|contents|excerpt|GUID|permalink|iconURL|categories|date|dateReceived|unread|flagged|collapsed|noComments\n2003|5||'Mactel' desktops may offer triple-threat OS|0||Also: GE, IBM and GM: the welfare kings|http://news.com.com/News.com+Extra/2001-9373_3-0.html?part=rss&amp;tag=rsspr.5748612&amp;subj=news|http://news.com.com/News.com+Extra/2001-9373_3-0.html?part=rss&amp;tag=rsspr.5748612&amp;subj=news|||140527020|140612922|1|||0\n2004|5||Virtual property becomes a reality|0||Blog: With the recent sentencing of a Chinese man who murdered an acquaintance in a dispute over a virtual sword, talk of the growing...|http://news.com.com/2061-10786_3-5748748.html?part=rss&amp;tag=5748748&amp;subj=news|http://news.com.com/2061-10786_3-5748748.html?part=rss&amp;tag=5748748&amp;subj=news|||140579040|140612922|1|||0\n</pre>\n\n<p>There's one piece up there that had me do a coffee spit-take, though:</p>\n<p><code>x_monkey TEXT,x_ninja TEXT,x_pirate TEXT,x_robot TEXT</code></p>\n<p>Seems like the Syndication Wars have progressed, and the various sides have enlisted all of these combatting factions.  <a href=\"http://www.swervepictures.com/monkey.htm\">Monkey vs Robot</a>, <a href=\"http://daily.stanford.edu/tempo?page=content&amp;id=17374&amp;repository=0001_article\">Pirates vs Ninja</a>--I only wonder whether the Ninjas and Robots will ally against the Monkeys and Pirates?  It just seems natural.</p>\n<!--more-->\n\n\n<p>shortname=safarirssdb</p>\n<div id=\"comments\" class=\"comments archived-comments\"><h3>Archived Comments</h3>\n<ul class=\"comments\">\n<li class=\"comment\" id=\"comment-221088083\">\n<div class=\"meta\">\n<div class=\"author\">\n<a class=\"avatar image\" rel=\"nofollow\" href=\"http://www.scifihifi.com\"><img src=\"http://www.gravatar.com/avatar.php?gravatar_id=266511c4b3124a981ccd3b1716e0bb0b&amp;size=32&amp;default=http://mediacdn.disqus.com/1320279820/images/noavatar32.png\" width=\"\" height=\"\"></a>\n<a class=\"avatar name\" rel=\"nofollow\" href=\"http://www.scifihifi.com\">Buzz Andersen</a>\n</div>\n\n\n<p><a href=\"#comment-221088083\" class=\"permalink\"><time datetime=\"2005-06-28T13:42:04\">2005-06-28T13:42:04</time></a></p>\n</div>\n\n\n<div class=\"content\">Syndication framework doesn't actually use Core Data.  The two were developed concurrently during Tiger, so Syndication wasn't built on top of Core Data.</div>\n\n\n</li>\n<li class=\"comment\" id=\"comment-221088085\">\n<div class=\"meta\">\n<div class=\"author\">\n<a class=\"avatar image\" rel=\"nofollow\" href=\"http://www.zerolives.org\"><img src=\"http://www.gravatar.com/avatar.php?gravatar_id=6e4d4f379af54c22de79175bb9747bc5&amp;size=32&amp;default=http://mediacdn.disqus.com/1320279820/images/noavatar32.png\" width=\"\" height=\"\"></a>\n<a class=\"avatar name\" rel=\"nofollow\" href=\"http://www.zerolives.org\">Phil</a>\n</div>\n\n\n<p><a href=\"#comment-221088085\" class=\"permalink\"><time datetime=\"2005-06-28T14:47:36\">2005-06-28T14:47:36</time></a></p>\n</div>\n\n\n<div class=\"content\">Wow, this is pretty interesting from a programmer's perspective.</div>\n\n\n</li>\n<li class=\"comment\" id=\"comment-221088086\">\n<div class=\"meta\">\n<div class=\"author\">\n<a class=\"avatar image\" rel=\"nofollow\" href=\"http://mooseyard.com/Jens\"><img src=\"http://www.gravatar.com/avatar.php?gravatar_id=f5364c1bb2137015586ae2820ee24ee9&amp;size=32&amp;default=http://mediacdn.disqus.com/1320279820/images/noavatar32.png\" width=\"\" height=\"\"></a>\n<a class=\"avatar name\" rel=\"nofollow\" href=\"http://mooseyard.com/Jens\">Jens Alfke</a>\n</div>\n\n\n<p><a href=\"#comment-221088086\" class=\"permalink\"><time datetime=\"2005-12-13T18:50:02\">2005-12-13T18:50:02</time></a></p>\n</div>\n\n\n<div class=\"content\"><p>The column names were inspired by the freebie game <a href=\"http://www.atomicsockmonkey.com/freebies/MNPR.pdf\" rel=\"nofollow\">Monkey, Ninja, Pirate, Robot</a> published by Atomic Sock Monkey. It's fun! Try it!</p>\n<p>The fact that there are weird column names was inspired by sqlite's (then-)inability to add columns to existing tables. So the last time I had to break the schema to add a new column, I added four more as a reserve.</p>\n<p>Needless to say, the contents, schema and very existence of that database are subject to change without notice, etc. etc.</p></div>\n\n\n</li>\n</ul>\n\n\n</div>\n\n\n",
  "body": "Hey, what do you know?  The database used by `Syndication.framework` on OS X is accessible with [SQLite 3][sl3], assumedly by virtue of [Core Data][cd].  Check out this barely presentable capture of what I just did in a shell window:\r\n\r\n[sl3]: http://www.sqlite.org/version3.html\r\n[cd]: http://developer.apple.com/macosx/coredata.html\r\n\r\n<pre style=\"font-size: 0.75em; overflow: auto\">\r\n[11:34:49] deusx@Caffeina2:~/Library/Syndication$ sqlite3 Database3 \r\nSQLite version 3.0.8\r\nEnter \".help\" for instructions\r\nsqlite> .tables\r\n\r\nArticles  Sources \r\n\r\nsqlite> .schema Articles\r\n\r\nCREATE TABLE Articles (id INTEGER PRIMARY KEY,\r\nsource_id INTEGER,author TEXT,title TEXT,contentType INT(1),\r\ncontents TEXT,excerpt TEXT,GUID TEXT,permalink TEXT,iconURL TEXT,\r\ncategories TEXT,date DATETIME,dateReceived DATETIME,unread INT(1),\r\nflagged INT(1),collapsed INT(1),noComments INT(1));\r\nCREATE INDEX ArticleCurrents ON Articles (noComments);\r\nCREATE INDEX ArticleDates ON Articles (date);\r\nCREATE INDEX ArticleDatesRcvd ON Articles (dateReceived);\r\nCREATE INDEX ArticleSources ON Articles (source_id);\r\nCREATE INDEX ArticleUnreads ON Articles (unread);\r\n\r\nsqlite> .schema Sources\r\n\r\nCREATE TABLE Sources (id INTEGER PRIMARY KEY,URL TEXT,\r\nsubscribed INT(1),title TEXT,iconURL TEXT,date INT,lastCheck INT,\r\nlastUpdate INT,slider INT(1),description TEXT,homePage TEXT,\r\ntimespan INT(1),sort INT(1),HTTPdate VARCHAR,feedHash VARCHAR(40),\r\nFOAFURL TEXT,protocol VARCHAR,lastError VARCHAR,maxDays INT(2),\r\nmaxArticles INT(2),x_monkey TEXT,x_ninja TEXT,x_pirate TEXT,\r\nx_robot TEXT);\r\n\r\nsqlite> select * from Sources;\r\n\r\nid|URL|subscribed|title|iconURL|date|lastCheck|lastUpdate|slider|description|homePage|timespan|sort|HTTPdate|feedHash|FOAFURL|protocol|lastError|maxDays|maxArticles|x_monkey|x_ninja|x_pirate|x_robot\r\n1|http://www.apple.com/main/rss/hotnews/hotnews.rss|1|Apple Hot News||141617700|141648125|141648128|||http://www.apple.com/hotnews/|||Tue, 28 Jun 2005 02:15:00 GMT|150fdf111cd223367f5c0cb8d28c65ec2a4ec195||RSS|||||||\r\n2|http://ax.phobos.apple.com.edgesuite.net/WebObjects/MZStore.woa/wpa/MRSS/newreleases/limit=25/rss.xml|1|iTunes 25 New Releases|/images/rss/badge.gif|141577349|141648124|141648126|||http://phobos.apple.com/WebObjects/MZStore.woa/wa/com.apple.jingle.app.store.DirectAction/viewNewReleases?pageType=newReleases&id=1|||Mon, 27 Jun 2005 18:02:29 GMT|8a2c02423581414b223f4533f0bf89211e1aa6c7||RSS|||||||\r\n\r\n...\r\n\r\nsqlite> select * from Articles;\r\n\r\nid|source_id|author|title|contentType|contents|excerpt|GUID|permalink|iconURL|categories|date|dateReceived|unread|flagged|collapsed|noComments\r\n2003|5||'Mactel' desktops may offer triple-threat OS|0||Also: GE, IBM and GM: the welfare kings|http://news.com.com/News.com+Extra/2001-9373_3-0.html?part=rss&tag=rsspr.5748612&subj=news|http://news.com.com/News.com+Extra/2001-9373_3-0.html?part=rss&tag=rsspr.5748612&subj=news|||140527020|140612922|1|||0\r\n2004|5||Virtual property becomes a reality|0||Blog: With the recent sentencing of a Chinese man who murdered an acquaintance in a dispute over a virtual sword, talk of the growing...|http://news.com.com/2061-10786_3-5748748.html?part=rss&tag=5748748&subj=news|http://news.com.com/2061-10786_3-5748748.html?part=rss&tag=5748748&subj=news|||140579040|140612922|1|||0\r\n</pre>\r\n\r\nThere's one piece up there that had me do a coffee spit-take, though:\r\n\r\n`x_monkey TEXT,x_ninja TEXT,x_pirate TEXT,x_robot TEXT`\r\n\r\nSeems like the Syndication Wars have progressed, and the various sides have enlisted all of these combatting factions.  [Monkey vs Robot][mvr], [Pirates vs Ninja][pvn]--I only wonder whether the Ninjas and Robots will ally against the Monkeys and Pirates?  It just seems natural.\r\n\r\n[mvr]: http://www.swervepictures.com/monkey.htm\r\n[pvn]: http://daily.stanford.edu/tempo?page=content&id=17374&repository=0001_article\r\n<!--more-->\r\nshortname=safarirssdb\r\n\r\n<div id=\"comments\" class=\"comments archived-comments\">\r\n            <h3>Archived Comments</h3>\r\n            \r\n        <ul class=\"comments\">\r\n            \r\n        <li class=\"comment\" id=\"comment-221088083\">\r\n            <div class=\"meta\">\r\n                <div class=\"author\">\r\n                    <a class=\"avatar image\" rel=\"nofollow\" \r\n                       href=\"http://www.scifihifi.com\"><img src=\"http://www.gravatar.com/avatar.php?gravatar_id=266511c4b3124a981ccd3b1716e0bb0b&amp;size=32&amp;default=http://mediacdn.disqus.com/1320279820/images/noavatar32.png\"/></a>\r\n                    <a class=\"avatar name\" rel=\"nofollow\" \r\n                       href=\"http://www.scifihifi.com\">Buzz Andersen</a>\r\n                </div>\r\n                <a href=\"#comment-221088083\" class=\"permalink\"><time datetime=\"2005-06-28T13:42:04\">2005-06-28T13:42:04</time></a>\r\n            </div>\r\n            <div class=\"content\">Syndication framework doesn't actually use Core Data.  The two were developed concurrently during Tiger, so Syndication wasn't built on top of Core Data.</div>\r\n            \r\n        </li>\r\n    \r\n        <li class=\"comment\" id=\"comment-221088085\">\r\n            <div class=\"meta\">\r\n                <div class=\"author\">\r\n                    <a class=\"avatar image\" rel=\"nofollow\" \r\n                       href=\"http://www.zerolives.org\"><img src=\"http://www.gravatar.com/avatar.php?gravatar_id=6e4d4f379af54c22de79175bb9747bc5&amp;size=32&amp;default=http://mediacdn.disqus.com/1320279820/images/noavatar32.png\"/></a>\r\n                    <a class=\"avatar name\" rel=\"nofollow\" \r\n                       href=\"http://www.zerolives.org\">Phil</a>\r\n                </div>\r\n                <a href=\"#comment-221088085\" class=\"permalink\"><time datetime=\"2005-06-28T14:47:36\">2005-06-28T14:47:36</time></a>\r\n            </div>\r\n            <div class=\"content\">Wow, this is pretty interesting from a programmer's perspective.</div>\r\n            \r\n        </li>\r\n    \r\n        <li class=\"comment\" id=\"comment-221088086\">\r\n            <div class=\"meta\">\r\n                <div class=\"author\">\r\n                    <a class=\"avatar image\" rel=\"nofollow\" \r\n                       href=\"http://mooseyard.com/Jens\"><img src=\"http://www.gravatar.com/avatar.php?gravatar_id=f5364c1bb2137015586ae2820ee24ee9&amp;size=32&amp;default=http://mediacdn.disqus.com/1320279820/images/noavatar32.png\"/></a>\r\n                    <a class=\"avatar name\" rel=\"nofollow\" \r\n                       href=\"http://mooseyard.com/Jens\">Jens Alfke</a>\r\n                </div>\r\n                <a href=\"#comment-221088086\" class=\"permalink\"><time datetime=\"2005-12-13T18:50:02\">2005-12-13T18:50:02</time></a>\r\n            </div>\r\n            <div class=\"content\"><p>The column names were inspired by the freebie game <a href=\"http://www.atomicsockmonkey.com/freebies/MNPR.pdf\" rel=\"nofollow\">Monkey, Ninja, Pirate, Robot</a> published by Atomic Sock Monkey. It's fun! Try it!</p>\r\n\r\n<p>The fact that there are weird column names was inspired by sqlite's (then-)inability to add columns to existing tables. So the last time I had to break the schema to add a new column, I added four more as a reserve.</p>\r\n\r\n<p>Needless to say, the contents, schema and very existence of that database are subject to change without notice, etc. etc.</p></div>\r\n            \r\n        </li>\r\n    \r\n        </ul>\r\n    \r\n        </div>\r\n    ",
  "parentPath": "./content/posts/archives/2005",
  "path": "2005/06/28/safarirssdb",
  "summary": "Hey, what do you know?  The database used by Syndication.framework on OS X is accessible with SQLite 3, assumedly by virtue of Core Data.  Check out this barely presentable capture of what I just did in a shell window:\n[11:34:49] deusx@Caffeina2:~/Library/Syndication$ sqlite3 Database3 \nSQLite version 3.0.8\nEnter \".help\" for instructions\nsqlite> .tables\n\nArticles  Sources \n\nsqlite> .schema Articles\n\nCREATE TABLE Articles (id INTEGER PRIMARY KEY,\nsource_id INTEGER,author TEXT,title TEXT,contentType INT(1),\ncontents TEXT,excerpt TEXT,GUID TEXT,permalink TEXT,iconURL TEXT,\ncategories TEXT,date DATETIME,dateReceived DATETIME,unread INT(1),\nflagged INT(1),collapsed INT(1),noComments INT(1));\nCREATE INDEX ArticleCurrents ON Articles (noComments);\nCREATE INDEX ArticleDates ON Articles (date);\nCREATE INDEX ArticleDatesRcvd ON Articles (dateReceived);\nCREATE INDEX ArticleSources ON Articles (source_id);\nCREATE INDEX ArticleUnreads ON Articles (unread);\n\nsqlite> .schema Sources\n\nCREATE TABLE Sources (id INTEGER PRIMARY KEY,URL TEXT,\nsubscribed INT(1),title TEXT,iconURL TEXT,date INT,lastCheck INT,\nlastUpdate INT,slider INT(1),description TEXT,homePage TEXT,\ntimespan INT(1),sort INT(1),HTTPdate VARCHAR,feedHash VARCHAR(40),\nFOAFURL TEXT,protocol VARCHAR,lastError VARCHAR,maxDays INT(2),\nmaxArticles INT(2),x_monkey TEXT,x_ninja TEXT,x_pirate TEXT,\nx_robot TEXT);\n\nsqlite> select * from Sources;\n\nid|URL|subscribed|title|iconURL|date|lastCheck|lastUpdate|slider|description|homePage|timespan|sort|HTTPdate|feedHash|FOAFURL|protocol|lastError|maxDays|maxArticles|x_monkey|x_ninja|x_pirate|x_robot\n1|http://www.apple.com/main/rss/hotnews/hotnews.rss|1|Apple Hot News||141617700|141648125|141648128|||http://www.apple.com/hotnews/|||Tue, 28 Jun 2005 02:15:00 GMT|150fdf111cd223367f5c0cb8d28c65ec2a4ec195||RSS|||||||\n2|http://ax.phobos.apple.com.edgesuite.net/WebObjects/MZStore.woa/wpa/MRSS/newreleases/limit=25/rss.xml|1|iTunes 25 New Releases|/images/rss/badge.gif|141577349|141648124|141648126|||http://phobos.apple.com/WebObjects/MZStore.woa/wa/com.apple.jingle.app.store.DirectAction/viewNewReleases?pageType=newReleases&id=1|||Mon, 27 Jun 2005 18:02:29 GMT|8a2c02423581414b223f4533f0bf89211e1aa6c7||RSS|||||||\n\n...\n\nsqlite> select * from Articles;\n\nid|source_id|author|title|contentType|contents|excerpt|GUID|permalink|iconURL|categories|date|dateReceived|unread|flagged|collapsed|noComments\n2003|5||'Mactel' desktops may offer triple-threat OS|0||Also: GE, IBM and GM: the welfare kings|http://news.com.com/News.com+Extra/2001-9373_3-0.html?part=rss&tag=rsspr.5748612&subj=news|http://news.com.com/News.com+Extra/2001-9373_3-0.html?part=rss&tag=rsspr.5748612&subj=news|||140527020|140612922|1|||0\n2004|5||Virtual property becomes a reality|0||Blog: With the recent sentencing of a Chinese man who murdered an acquaintance in a dispute over a virtual sword, talk of the growing...|http://news.com.com/2061-10786_3-5748748.html?part=rss&tag=5748748&subj=news|http://news.com.com/2061-10786_3-5748748.html?part=rss&tag=5748748&subj=news|||140579040|140612922|1|||0\n\n\nThere's one piece up there that had me do a coffee spit-take, though:\nx_monkey TEXT,x_ninja TEXT,x_pirate TEXT,x_robot TEXT\nSeems like the Syndication Wars have progressed, and the various sides have enlisted all of these combatting factions.  Monkey vs Robot, Pirates vs Ninja--I only wonder whether the Ninjas and Robots will ally against the Monkeys and Pirates?  It just seems natural.",
  "needsBuild": true,
  "prevPostPath": "2005/06/28/four-thoughts-on-ms-rss-so-far",
  "prevPostTitle": "Four thoughts on MS RSS so far",
  "nextPostPath": "2005/06/28/quick-postlunch",
  "nextPostTitle": "Quick post-lunch OS X and iTunes dribblings"
}