Questions tagged [pysolr]

A lightweight Python library for connecting to an Apache SOLR instance.

98 questions
26
votes
2 answers

How to add something to PYTHONPATH?

I downloaded a package (called pysolr 2.0.15) to my computer to be used with Haystack. The instructions asks me to add pysolr to my PYTHONPATH. What exactly does that mean? After extracting the pysolr files, I ran the command python setup.py install…
goelv
  • 2,774
  • 11
  • 32
  • 40
9
votes
2 answers

django-haystack: Failed to add documents to Solr: [Reason: Error 404 Not Found]

I'm using django-haystack (v 2.3.1) with solr (v 5.0.0) and pysolr (v 3.0.0). I've been following the tutorial, and have set up similar myapp/search_indexes.py and search/indexes/myapp/mymodel_text.txt files. ./manage.py build_solr_schema >…
gatlanticus
  • 1,158
  • 2
  • 14
  • 28
9
votes
2 answers

Django, Haystack, Solr and Boosting

TLDR; How does various boosting types work together in django, django-haystack and solr? I am having trouble getting the most obvious search results to appear first. If I search for caring for others and get 10 results, The object with title caring…
Francis Yaconiello
  • 10,829
  • 2
  • 35
  • 54
5
votes
1 answer

Django/python and Apache Solr: pysolr or solrpy?

brand new on this forum and this is my first post! At work we're starting a project which uses Apache Solr and i'm in charge of the frontend system (Django-based). Our solr database isn't related to any other db engine nor to any models' class, so…
Samuele Mattiuzzo
  • 10,760
  • 5
  • 39
  • 63
5
votes
3 answers

Failed to add documents to Solr: Solr responded with an error (HTTP 400) (django + haystack + solr)

I currently have Solr 4.2.0 working in production (set up around 2012). I have set up a new development environment where I upgraded all packages (Django 1.8.10, PySolr 3.4.0, Haystack 2.4.1) and set up Solr 5.5.0 In short I have Solr running, my…
Jos van Leeuwen
  • 263
  • 3
  • 8
4
votes
2 answers

Django-Haystack and Solr 8.5.1

Does Django haystack work with the latest Solr update (8.5.1)? Plus how do I setup with my Django blog project
Charles
  • 63
  • 1
  • 6
4
votes
2 answers

Solr search with escaping solr reserved keywords

How do i query fields that contain solr reserved keywords as ":" in solr? For instance, q = 'uri:http://www.example.com' throws up an error for "http://www.example.com" containing reserved word ":"
Mohit Ranka
  • 4,193
  • 12
  • 41
  • 41
4
votes
5 answers

Total number of documents in pysolr

How can I get the total number of documents matching the given query. I have use the query below: result = solr.search('ad_id : 20') print(len(result)) Since the default returning value is '10', the output is only 10, but the count is 4000. How can…
Manish Ojha
  • 515
  • 1
  • 8
  • 26
4
votes
1 answer

pysolr update document with error

update: Pysolr Version: 3.2.0 This seems a bug in solr. when update nothing in an operation, it will delete this doc. Former I used code in using pysolr in atomic update, but I made error in following case. Now a document schema maybe like this: doc…
yomin
  • 551
  • 5
  • 14
4
votes
1 answer

How to use facets with PySolr - can't seem to get facet results to show

(I have seen similar questions to this - but cannot seem to resolve why the below doesnt work!) Hi, I have a running local instance of solr and make the following call (via the url box in my…
user7289
  • 32,560
  • 28
  • 71
  • 88
3
votes
1 answer

Pysolr filter search

I am using pysolr-2.0.15 api for Solr searching mysite:8983/solr/select/?q=disease&fq=url:"pediatric"&version=2.2&start=0&rows=10&indent=on This Solr query gives me successful result I want to implement this using pysolr search function I am…
Muhammad Umair
  • 393
  • 1
  • 7
  • 20
3
votes
1 answer

Solr More Like This (MLT) not returning results

I'm currently looking to implement more like this functionality based on a on a number of fields in my index. My current configuration is as follows: Haystack | PySolr | Solr For this piece I'm using PySolr and passing the parameters to the…
Naqeeb
  • 245
  • 4
  • 10
3
votes
3 answers

Connection to solr cloud collection using pysolr

I have configured a multicore solr cloud. Created a collection with 2 shrads and no replication. Through the solr UI 192.168.1.56:8983, I am able to get results to the query. I want to do the same with pysolr, so tried running following: import…
Pramod Patil
  • 757
  • 2
  • 10
  • 26
3
votes
1 answer

Apache Solr 6.6 replace document instead of update

I have configured solr 6.6.1 for a testing setup. After indexing few documents, I have to update few fields. I am using python client of solr. To update, following is my code snippet import solr def update_solr_index(_id, _value): print…
Hafiz Muhammad Shafiq
  • 8,168
  • 12
  • 63
  • 121
3
votes
1 answer

pysolr: HTTP method POST not supported by this url

I am new to Solr and PySolr and I am trying to create a web-app. I am planning to use PySolr but when I try to run an example script I get errors. Below are the details: import pysolr # Setup a Solr instance. The timeout is optional. solr =…
Pukki
  • 586
  • 1
  • 7
  • 18
1
2 3 4 5 6 7