Questions tagged [pysolr]

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

98 questions
0
votes
1 answer

code showing empty dataframe

I write the below code for my project but dataframe df showing empty records.I want to know where i am lacking in the code: import urllib from urllib2 import * import pandas as pd def urlmake(req): requests = [req] for parms in requests: …
Saurabh
  • 21
  • 7
0
votes
1 answer

how to use urlopen for dynamic query string

I am working with python and solr and load the data from solr to python through url as: connection = urlopen('http://localhost:8983/solr/data/select?indent=on&q=sender_name:*AX*%20AND%20message:*Avail%20Lmt&rows=211&start=0&wt=json') if i have to…
Saurabh
  • 21
  • 7
0
votes
1 answer

Giving error while accessing data through urllib

I am working with solr and python.I use urllib library to get http data. I write code as: from urllib2 import * connection = urlopen('http://localhost:8983/solr/data/select?indent=on&q=sender_name:*AXI*&wt=json') It was working fine but when I…
Saurabh
  • 21
  • 7
0
votes
1 answer

Transfer data from solr to python

I am beginner to solr.i want to transfer the data from solr to python and i have found the pysolr library i have installed it but did'nt know how to use it. I have searched on google but did'nt find required answer I want to ask how we can load data…
Saurabh
  • 21
  • 7
0
votes
1 answer

How to do facet search with Pysolr

when we use curl or urlopen with facet to execute queries, we get a nested dictionary with 3 elements 1. responseHeader 2. response 3. facet_counts I want to show the facet_counts while using Pysolr search. It just shows the 'response' value of the…
Rohan Garg
  • 35
  • 5
0
votes
0 answers

pySolr : Adding a multivalued field

I would like to fill an solr index from a pandas dataframe. The dataframe is as follows: position value 5.6,-2.3 65 -35.6,-1.2 43.1 #... etc. I am doing the following to transform the dataframe to a json object and then adding…
ma3oun
  • 3,681
  • 1
  • 21
  • 33
0
votes
1 answer

Any idea to set q.op in pysolr?

The following code doesn't work.... any idea? thanks. Couldn't find any reference about it... import pysolr .... self.solr = pysolr.Solr(solr_url, timeout=20) docs = self.solr.search(q=q, q.op =q_op) Can I just use self.solr.search(q=q, op =q_op)…
Chandler.Huang
  • 873
  • 3
  • 12
  • 24
0
votes
1 answer

how to load a JSON file to solr using `pysolr`?

The following python code adds a document but without the json contents: solr_instance = pysolr.Solr('http://192.168.45.153:8983/solr/test', timeout=60) json_filename = '/path/to/file/test.json' argws = { 'commit': 'true', 'extractOnly':…
wolfrevo
  • 6,651
  • 2
  • 26
  • 38
0
votes
1 answer

pysolr - issue with adding to index?

EDIT: Comma or no after "A test document" and after the '}' yields the same result Currently trying to use pysolr on my solr installation. FYI my solr admin page starts and loads at http://localhost:8983/solr/ just fine The following is a snippet of…
user3210680
  • 98
  • 1
  • 1
  • 7
0
votes
1 answer

Can we migrate non stored Index data in SOLR to Elastic search?

We are currently using SOLR for full-text search. Now we are planning to move from SOLR to ElasticSearch. When we were in this process i have read somewhere that there are some plugins available which will migrate data from SOLR-ElasticSearch. But…
Adarsh H D Dev
  • 588
  • 7
  • 29
0
votes
1 answer

mongo-connector is not syncing data from MongoDB to Solr

I need to syncing data from MongoDB to Solr. when i issue the command mongo-connector -m dbserver:27018 -n shop -t http://localhost:8983/solr/Search --auto-commit-interval=0 -d solr_doc_manager the error log is: 2016-12-13 15:21:40,461 [CRITICAL]…
Telen
  • 185
  • 1
  • 4
  • 17
0
votes
1 answer

Trouble adding data to Solr with python?

I am using python 3.4.3 and sunburnt to add some document to Solr(5.2.1). The following code is directly from the Sunburnt documentation: import sunburnt si=sunburnt.SolrInterface("http://localhost:8983/solr/") document = {"id":"0553573403", …
ajaanbaahu
  • 344
  • 3
  • 20
0
votes
1 answer

Solr 5.3 my core's /update url not found

I create a core in solr 5.3 using haystack for my django application and try to do python manage.py rebuild_index, it just gives this error message. The part /update/?commit=true looks strange for me. I try to manually change it to…
MC X
  • 337
  • 4
  • 16
0
votes
1 answer

pysolr python can no decode json

I got a pysolr instance and I try to get this simple query. I use python 2.7 and pysolr 3.3.2: When I get this query: solrDoc.search('platformID:RO', **{'rows': 0, 'start':5, 'sort':'id DESC'}) I have this Json exception: File…
mathieu
  • 53
  • 7
0
votes
1 answer

'NoneType' object has no attribute 'rstrip' haystack

I am using haystack backend solr. I am getting a weird error 'NoneType' object has no attribute 'rstrip' I have updated my index many times, checked the versions etc etc but nothing has worked. Here is my SearchIndex file: class…
madeeha ameer
  • 479
  • 2
  • 8
  • 22