Questions tagged [sunspot-rails]

Sunspot Rails Plugin

Sunspot Rails is a Rails plugin that provides drop-in integration of the Sunspot[http://outoftime.github.com/sunspot] Solr search library with Rails

411 questions
0
votes
1 answer

Is it possible to merge two association tables in Sunspot solr

I have four tables. They are Brands, departments, categories and product_details. The models are Brand model class Brand < ActiveRecord::Base has_many :product_details, :dependent=>:destroy searchable do integer :id text :name …
web spider26
  • 252
  • 4
  • 16
0
votes
2 answers

Rails sunspot: re-indexing of an associated model does not run as a delayed job

I am using sunspot in combination with delayed job to perform re-indexing of my models as an asynchronous background process. For model updates this works fine due to: handle_asynchronously :solr_index, :queue => 'solr_index'. However, the…
dblp1
  • 35
  • 2
0
votes
1 answer

Rails 3.2 sunspot_rails and sunspot_solr wont get started on Windows

Edit: Downloaded the zip and installed it manually, now everything works fine. Unfortunately it seems to be impossible to set up Sunspot and Solr on Windows. Running rake sunspot:solr:run works fine, however, when trying to reindex or if on server…
0
votes
1 answer

sunspot how query specific field

Reading through Sunspot documentation I am trying to find how I can query autocomplete fields. I create them like here https://github.com/haitham/sunspot_autocomplete Here is config solr/conf/schema.xml .......
Volodymyr
  • 1,136
  • 3
  • 11
  • 28
0
votes
1 answer

Rails3 sunspot has_many assoctiation

I have trouble with searching with the sunspot gem. I want to search for user email in an object tenant. tenant has many users In the tenant I did this: searchable do text :name, :notifications_email text :users do users.map(&:email) …
michael_knight
  • 4,921
  • 3
  • 17
  • 10
0
votes
2 answers

Undefined field error in sunspot_solr grouping clause

I have product_details table which belongs to categories. product_details has fields like id, name, price, discount and category_id and categories table has fields like id and name. Am using mysql database Am trying to do group product details based…
web spider26
  • 252
  • 4
  • 16
0
votes
1 answer

Is it possible to add "search" function to the messaging gem "Mailboxer"?

I'd like to implement "text search function" over body part of tons messages. If anyone knows how to implement that to "Mailboxer", please show me how. I have no idea how it goes. When I access…
MKK
  • 2,713
  • 5
  • 31
  • 51
0
votes
1 answer

Grouping Sunspot Models to get sorting/count on View

@search = Sunspot.search(Event, Person, Organization) do keywords params[:q] order_by(:score) end Based on the search results I'd like to create a list of Models with counts for each model. Events (12) People (5) Organizations (3) Is…
Walksalong
  • 191
  • 2
  • 13
0
votes
1 answer

how to write search method code to search more than one id at a time

In my project am trying to display products based on user choice. User can check which department(women, men and kids) and category (dress, tops, tees etc) they wish to see. For this am using check box. If user checks(selects) only women departments…
web spider26
  • 252
  • 4
  • 16
0
votes
2 answers

Sunspot scoped queries not working

I'm implementing a fulltext search using Sunspot with scoped queries, but it's not working. When I remove the 'with' queries and search, it works, but when I add the queries in it does not. I've looked at the documentation and it should be…
ahuang7
  • 804
  • 1
  • 11
  • 26
0
votes
1 answer

how to run sunspot reindex in background for every four hours

I want to execute rake sunspot:reindex RAILS_ENV=production command for every four hours. To achieve this i have written simple bash script using shell programming. I will run successfully in terminal but if i tried to run it in crontab then it is…
web spider26
  • 252
  • 4
  • 16
0
votes
2 answers

Solr minimum match results ranking

In my Rails application I have a Question model, setup with sunspot solr, with a field "text" and I'd like to search in that field doing a logical OR between words. I've found that setting minimum_match to 1 solves my problem, however I'd like also…
0
votes
1 answer

How to index a virtual field that changes with respect to time

I have a virtual field weight that changes based on the difference in time between now and object created_at time. I want to update it in Sunspot every 2 hours, so I was planning to call Topic.solr_index. However I think Sunspot will only index…
lulalala
  • 17,572
  • 15
  • 110
  • 169
0
votes
2 answers

how to configure edismax handler in sunspot?

can any one explain how to start with using edismax request handler in sunspot? I want to use wild card search in my application. currently dismax handler is there.i searched and found that edismax is only option for wild card search.*please give me…
Raj gupta
  • 51
  • 5
0
votes
1 answer

Searching String Fields Using Sunspot and Rails

My team is attempting to implement Solr and Sunspot-Rails as a search provider for our application. Our story requires that certain string fields be searched in addition to the text fields. I have seen some people aggregate these fields into a…
KillJones
  • 3
  • 3
1 2 3
27
28