django-sphinx

How do I automatically rebuild the Sphinx index under django-sphinx?

I just setup django-sphinx, and it is working beautifully. I am now able to search my model and get amazing results. The one problem is that I have to build the index by hand using the indexer command. That means every time I add new content, I have to manually hit the command line to rebuild the search index. That is just not acceptable...

Querying multiple index in django-sphinx

The django-sphinx documentation shows that django-sphinx layer also supports some basic querying over multiple indexes. http://github.com/dcramer/django-sphinx/blob/master/README.rst from djangosphinx.models import SphinxSearch SphinxSearch('index1 index2 index3').query('hello') It seems SphinxSearch does not contain the function qu...

How to get field name......

Recently i have implemented django-sphinx search on my website. It is working fine of each separate model. But now my client requirement has changed. To implement that functionality i need field name to whom search is made. suppose my query is: "select id, name,description from table1" and search keyword is matched with value in field...

Problem with order_by in django sphinx

I have implemented django-sphinx search in my website. I need result set "order by end_time" but i got results oder by first "id" and then "end_time". My conf is: source main_event : main_civilengagement { sql_query = \ SELECT mc.id as id, mc.name as name, tt.name as ttname, mp.text as mptext, \ mc.descript...

where is SeparatedValuesField in my code, i used sphinx.

from django.db import models from djangosphinx import SphinxSearch # A sample model from iBegin class City(models.Model): name = models.CharField(max_length=32) aliases = SeparatedValuesField(blank=True, null=True)#<-------this slug = models.SlugField(blank=True) country = models.For...

django error ,about django-sphinx

from django.db import models from djangosphinx.models import SphinxSearch class MyModel(models.Model): search = SphinxSearch() # optional: defaults to db_table # If your index name does not match MyModel._meta.db_table # Note: You can only generate automatic configurations from the ./manage.py script # if your index name...

django error:connection to localhost;3312 failed ,i used django-sphinx.

Traceback (most recent call last): File "D:\Python25\Lib\site-packages\django\core\servers\basehttp.py", line 280, in run self.finish_response() File "D:\Python25\Lib\site-packages\django\core\servers\basehttp.py", line 319, in finish_response for data in self.result: File "D:\Python25\Lib\site-packages\django\http\__ini...

Everything is ok, but my 127.0.0.1:8000 can't show anything, why ? I used django-sphinx

from djangosphinx.models import SphinxSearch def xx(request): queryset =File.search.query('test') #return HttpResponse(queryset)#<------1 return render_to_response('a.html',{'a':queryset})#<--------2 and class File(models.Model): name = models.CharField(max_length=200) tags = models.CharField(max_length=200) # We ...

How to combine sphinxquerysets in djang-sphinx

querysets from django can be combined with a pipe like so: q1 = Articles.objects.filter(name="goats") q2 = Articles.objects.filter(name='cows') q1 = q1|q2. Is there a way to do this for sphinxquerysets? So far, I'm striking out. ...

Why does django-sphinx only output 20 results? How can I get the rest?

Doing a search using django-sphinx gives me results._sphinx that says there were 68 results, but when I iterate over them, I can only get at the first 20 of them. I'm SURE there's a way around this, and that this is by design, but it's officially stumping the heck out of me. Does anybody know how to get the complete queryset? ...

MySQL efficiency as it relates to the database/table size

I'm building a system using django, Sphinx and MySQL that's very quickly becoming quite large. The database currently has about 2000 rows, and I've written a program that's going to populate it with another 40,000 rows in a couple days. Since the database is live right now, and since I've never had a database with this much information i...

Django Sphinx Foreign key search

Hi, I'm trying to create full text search on model, everything goes fine when searching TextFields but I have a problem with ForeignKey field. How can i do that? Can anyone point me to the right direction? Thanks Model example: class Model1(models.Model): text_field =models.TextField(max_length=250) fk_field = models.ForeignKey('...

Django sphinx works only after app restart.

Hi, I've set up django-sphinx in my project, which works perfectly only for some time. Later it always returns empty result set. Surprisingly restarting django app fixes it. And search works again but again only for short time (or very limiter number of queries). Heres my sphinx.conf: source src_questions { # data source type ...

Sphinx Search Engine & Python API

I am trying to use Sphinx Search Engine with their Python API. The installation went fine. But when I use their Python API I do not get the complete result set. I only get the ID's? But when I use their ./search binary in ./bin I get the entire indexed content. When using cpp ./search binary - ./search test 1. document=1, weight=1, gr...

Django Sphinx Text Search

I am trying out Sphinx search in my Django project. All setup done & it works but need some clarification from someone who has actually used this setup. In my Sphinx search while indexing, I have used 'name' as the field in my MySQL to be searchable & all other fields in sql_query to be as attributes (according to Sphinx lingo). So wh...

Search app in Django

I am building search app using django & sphinx. I got the setup working but when I search I get irrelevant results. Here is what I do - # this is in my trial_data Model search = SphinxSearch( index = 'trial_data trial_datastemmed', weights = {'name': 100,}, mode = 'SPH_MATCH_A...