Freelancing Gods 2015

24 Oct 2008

Thinking Sphinx PDF at Peepcode

A quick note to let anyone using (or interested in using) Sphinx and/or Thinking Sphinx that my Peepcode PDF has just been published, and contains a wealth of information on how to mix Sphinx with ActiveRecord (via Rails or Merb).

It’s been great working with Geoffrey Grosenbach to get this written up, and I’m pretty stoked to see the final results – hopefully others will enjoy it as well.

Also, a massive thank you to all the contributors to Thinking Sphinx – it wouldn’t be quite so cool if it wasn’t for all the patches (facilitated by GitHub’s forking).


8 responses to this article

28 Oct 2008
Jeff said:

I’m excited about thinking sphinx, but I’ve never been able to get past an issue where a table whose id is a varchar refuses to be indexed… it throws “WARNING: duplicate document ids found” and refuses to index properly. I tried coding around the sql_query * 1 + 0 AS `id` bit on a hunch, but that doesn’t seem to solve it.

Any advice? I’m otherwise ready to shell out the cash for this pdf.

28 Oct 2008
jeff said:

I should note that the varchar ids are unique in the database.

28 Oct 2008
Jeff said:

So it appears that this is a limitation of sphinx itself. Sorry for the troubles. Even sorrier that I can’t use sphinx on this project.

29 Oct 2008
pat said:

Hi Jeff

Yup, unfortunately Sphinx requires integer IDs. Sorry it’s not a solution that’ll work for you.

20 Dec 2008
tashfeen said:

i get the following error when trying to start sphinx and the file noted there is not being generated. permission on the directory is for all.

(in C:/ror/rails_apps/drug)
searchd —config C:/ror/rails_apps/drug/config/development.sphinx.conf
Failed to start searchd daemon. Check C:/ror/rails_apps/drug/log/searchd.log.

21 Dec 2008
pat said:

Not quite sure what could be stopping development.sphinx.conf from generating… probably best to continue this discussion on the google group

22 Dec 2008
tashfeen said:

ok, treid there too but no help yet. let me know if you come up with anything. i am developing on windows if that may help…

06 Mar 2009
Jeff said:

Not trying to blog spam here, but for those who get here via google: Don’t be discouraged by the integer primary key issue, it can be overcome. See

Leave a Comment

Comments are formatted using Textile. Please be respectful of others when posting comments. Be nice.

RssSubscribe to the RSS feed

Related Links

Related Posts

About Freelancing Gods

Freelancing Gods is written by , who works on the web as a web developer in Melbourne, Australia, specialising in Ruby on Rails.

In case you're wondering what the likely content here will be about (besides code), keep in mind that Pat is passionate about the internet, music, politics, comedy, bringing people together, and making a difference. And pancakes.

His ego isn't as bad as you may think. Honest.

Here's more than you ever wanted to know.

Open Source Projects

Other Sites

Creative Commons Logo All original content on this site is available through a Creative Commons by-nc-sa licence.