<?xml version="1.0" encoding="utf-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	>
<channel>
	<title>Comments on: Loading Netflix Dataset into SQL</title>
	<atom:link href="http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/</link>
	<description>A goal is a dream with a deadline.</description>
	<pubDate>Tue, 16 Mar 2010 05:36:09 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Tom</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-200367</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Tue, 23 Jun 2009 15:58:31 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-200367</guid>
		<description>Thanks Aislan, that worked...

Now on to the next bit (this is my first foray into any sort of programming, so progress is slow...)

Tom</description>
		<content:encoded><![CDATA[<p>Thanks Aislan, that worked&#8230;</p>
<p>Now on to the next bit (this is my first foray into any sort of programming, so progress is slow&#8230;)</p>
<p>Tom</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Aislan</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-200176</link>
		<dc:creator>Aislan</dc:creator>
		<pubDate>Mon, 22 Jun 2009 13:48:43 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-200176</guid>
		<description>I got the same problem, maybe the format of the file changed. Anyway, I removed the parser line and add a simpler one and it worked:

#removed   
#id, year, title = movie.chomp.scan(/(\\d+),(\\d+&#124;NULL),(.*)/).flatten
#added
id, year, title = movie.chomp.split(",")

Regards,
Aislan</description>
		<content:encoded><![CDATA[<p>I got the same problem, maybe the format of the file changed. Anyway, I removed the parser line and add a simpler one and it worked:</p>
<p>#removed<br />
#id, year, title = movie.chomp.scan(/(\\d+),(\\d+|NULL),(.*)/).flatten<br />
#added<br />
id, year, title = movie.chomp.split(&#8221;,&#8221;)</p>
<p>Regards,<br />
Aislan</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199879</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Sat, 20 Jun 2009 16:14:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199879</guid>
		<description>Tom, have you tried adding some debugging output to the script? Is it picking up the file / reading in the lines correctly? 

You might have to do some tweaking if Netflix changed their format.</description>
		<content:encoded><![CDATA[<p>Tom, have you tried adding some debugging output to the script? Is it picking up the file / reading in the lines correctly? </p>
<p>You might have to do some tweaking if Netflix changed their format.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199614</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Wed, 17 Jun 2009 13:58:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199614</guid>
		<description>No, sorry Ilya I wasn't really clear there, running your netflix_movie_import.rb still returns:

exception: private method ‘gsub’ called for nil:NilClass.</description>
		<content:encoded><![CDATA[<p>No, sorry Ilya I wasn&#8217;t really clear there, running your netflix_movie_import.rb still returns:</p>
<p>exception: private method ‘gsub’ called for nil:NilClass.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199610</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Wed, 17 Jun 2009 12:48:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199610</guid>
		<description>Tom, glad to hear it's working!</description>
		<content:encoded><![CDATA[<p>Tom, glad to hear it&#8217;s working!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199600</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Wed, 17 Jun 2009 09:08:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199600</guid>
		<description>ps

The first way I tried it  - whihc gave the error message i left before was just to use "movie_titles.txt" . I tested whether ruby could read the file by running this:

my_file = 'movie_titles.txt'

f = File.open(my_file, 'r')
file_data = f.read
f.close

puts file_data

which worked.</description>
		<content:encoded><![CDATA[<p>ps</p>
<p>The first way I tried it  - whihc gave the error message i left before was just to use &#8220;movie_titles.txt&#8221; . I tested whether ruby could read the file by running this:</p>
<p>my_file = &#8216;movie_titles.txt&#8217;</p>
<p>f = File.open(my_file, &#8216;r&#8217;)<br />
file_data = f.read<br />
f.close</p>
<p>puts file_data</p>
<p>which worked.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199598</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Wed, 17 Jun 2009 08:44:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199598</guid>
		<description>Ilya,

I am running the program from C:\Ruby\Ruby Programs , and the movie_titles.txt file is in that folder.

Should I run the ruby script just the same as the version on the website or should I change "../movie_titles.txt" to something else?

Thanks in advance for what may seem like a daft question - i'm new...

Tom</description>
		<content:encoded><![CDATA[<p>Ilya,</p>
<p>I am running the program from C:\Ruby\Ruby Programs , and the movie_titles.txt file is in that folder.</p>
<p>Should I run the ruby script just the same as the version on the website or should I change &#8220;../movie_titles.txt&#8221; to something else?</p>
<p>Thanks in advance for what may seem like a daft question - i&#8217;m new&#8230;</p>
<p>Tom</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199548</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Wed, 17 Jun 2009 02:25:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199548</guid>
		<description>Tom, it sounds like the script just can't find the files on disk. Are you sure the following file exists with respect  to where you're running the import process from? (../movie_titles.txt)</description>
		<content:encoded><![CDATA[<p>Tom, it sounds like the script just can&#8217;t find the files on disk. Are you sure the following file exists with respect  to where you&#8217;re running the import process from? (../movie_titles.txt)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tom</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-199430</link>
		<dc:creator>Tom</dc:creator>
		<pubDate>Tue, 16 Jun 2009 11:39:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-199430</guid>
		<description>I'm new to both sql and ruby, but trying to have a go at playing with the netflix data.

when I run the netflix_movie_import.rb file I get the reply:

exception: private method 'gsub' called for nil:NilClass

and movies-import.sql file i get only has this in it:

  USE `netflix`;
        DROP TABLE IF EXISTS `movies`;
        CREATE TABLE `movies` (
          `id` int(5) NOT NULL default '0',
          `year` int(4) default '0',
          `title` varchar(255) NOT NULL default '',
          PRIMARY KEY  (`id`)
        ) ENGINE=MyISAM DEFAULT CHARSET=latin1;

I take it it should have all of the movie titles in it as well?

Any ideas where I am going wrong? (I'm using windows XP and Ruby 1.8.6

Thanks

Tom</description>
		<content:encoded><![CDATA[<p>I&#8217;m new to both sql and ruby, but trying to have a go at playing with the netflix data.</p>
<p>when I run the netflix_movie_import.rb file I get the reply:</p>
<p>exception: private method &#8216;gsub&#8217; called for nil:NilClass</p>
<p>and movies-import.sql file i get only has this in it:</p>
<p>  USE `netflix`;<br />
        DROP TABLE IF EXISTS `movies`;<br />
        CREATE TABLE `movies` (<br />
          `id` int(5) NOT NULL default &#8216;0&#8242;,<br />
          `year` int(4) default &#8216;0&#8242;,<br />
          `title` varchar(255) NOT NULL default &#8221;,<br />
          PRIMARY KEY  (`id`)<br />
        ) ENGINE=MyISAM DEFAULT CHARSET=latin1;</p>
<p>I take it it should have all of the movie titles in it as well?</p>
<p>Any ideas where I am going wrong? (I&#8217;m using windows XP and Ruby 1.8.6</p>
<p>Thanks</p>
<p>Tom</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2006/12/01/loading-netflix-dataset-into-sql/comment-page-1/#comment-103825</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Fri, 06 Jun 2008 12:07:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2006/12/01/loading-netflix-dataset-into-sql/#comment-103825</guid>
		<description>Awesome, thanks for sharing the tips Larry!</description>
		<content:encoded><![CDATA[<p>Awesome, thanks for sharing the tips Larry!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
