similar to: Is aaf multi_search broken?

Displaying 20 results from an estimated 600 matches similar to: "Is aaf multi_search broken?"

2006 Oct 09
7
multi_search problems, Never go away!
Hello, I am trying to use the multi_search method, but I keep getting type error on nil objects, I send it [Model1,Model2] and it seems as though the class names keep getting clobbered and turn to nil, somewhere along the multi_index area. I tried to trace what was going on, but I got nothing, also, this only happens when there are actually hits(thank god, most of the time). Perhaps some insight?
2006 Dec 07
5
Search Multiple Models
Hello folks, I have four models, each with their own separate index. Models = Articles, Blogs, MusicTracks, and MediaFiles I have individual searches within each section of the site working just fine, but I want to have a gloabl search that searches across all of them at the same time and returns the results ordered by score. Here''s how far I am now... def search query =
2006 Nov 30
1
usage and benefits of single-index with AAF
The documentation states: "single_index: set this to true to let this class use a Ferret index that is shared by all classes having :single_index set to true. :store_class_name is set to true implicitly, as well as index_dir, so don?t bother setting these when using this option. the shared index will be located in index/<RAILS_ENV>/shared ." [1] If I''m reading
2006 Sep 20
5
acts_as_ferret limit on multi_search not working?
I''m using acts_as_ferret to do a query like this: Model1.multi_search("my query",[Model2,Model3], :limit => 2) No matter what number i set limit to I get 10 items in the resultset. Am I doing something wrong? Thanks/David -- Posted via http://www.ruby-forum.com/.
2006 May 18
1
multi_search problem
I am running into the following error when I try to search across multiple models with multi_search() I have rebuilt the indices and can search on each model individually using the Rails console. Here is the output from the console. >> Post.multi_search(''new'', [Message, WikiPage]) ArgumentError: wrong number of arguments (1 for 0) from
2007 Mar 27
1
multi_search problems
Hello. I''ve been trying to get multi_search to work and I simply can''t. I have two models: Post acts_as_ferret :fields => [:title, :body], :store_class_name => true Page acts_as_ferret :fields => [:title, :body], :store_class_name => true If I do @results = Post.find_by_contents(params[:q]) or @results = Page.find_by_contents(params[:q]) it works fine, but if I
2006 Oct 10
1
sorting results with aaf multi_search
Is it possible to sort the result of acts_as_ferret multi_search the way you can with find_contents? I''m using the latest ferret and aaf. I have an interface that offers multiple search options which search different fields of a single model. In addition to these, I also have an "all" search type which is meant to pull in one additional model and consider all indexed
2007 Aug 07
2
Varying case sensitivity
Hi all, I''m using ferret 11.4 together with acts_as_ferret and I''ve indexed the geonames.org country files. These files contain worldwide locations in UTF-8 with all their different spellings each. Model definition is like this: class location acts_as_ferret :fields => {:location_names => {}}, :single_index => true ... end The instance method location_names
2007 Mar 21
2
store_class_name for Comatose:Page model
Hi, I have three models: Comatose::Page, Article and Product. In all of them, store_class_name is set to true. Now, when i do: results = Comatose::Page.multi_search("*", [Article,Product], options) I get: wrong constant name Comatose::Page #{RAILS_ROOT}/vendor/plugins/acts_as_ferret/lib/class_methods.rb:438:in `const_get''
2006 Dec 16
10
Getting "ArgumentError ( isn''t a valid directory argument.
I''m hoping someone has encountered this before. I''m using AAF trunk and trying to multi_search across 2 models. It works fine on my windows (Webricks) dev env but now that i''ve deployed to linux, (Apache, FastCGI) I''m getting the following error: ArgumentError ( isn''t a valid directory argument. You should use either a String or a Directory):
2007 Apr 15
2
"tried to use a closed index"
Sorry in advance for the newbie question. Can''t get aaf going and can''t find similarly stuck folks on this forum. I''m running Rails on my local machine in development mode. I installed ferret 0.11.0 gem, and the most recent stable aaf plugin (as of today). I''m having trouble getting the most basic functionality working. In my model Recipe, I have:
2006 Oct 13
5
multi_search error undefined method
Hi, Im having problems using the multi_search command. I keep getting the following error. "undefined method `<<'' for Book:Class" here is the code associated with this. class Book < ActiveRecord::Base acts_as_ferret :store_class_name => true end class User < ActiveRecord::Base acts_as_ferret :store_class_name => true end and the call is the
2007 Feb 28
5
How to use find_options in multi_search
Hello everyone, I''m using multi-search to search in some attributes of two classes. One of the attributes is the id of the customer. For each multi_search I want to do a give the id of the current customer as a parameter. This should only return results for the given customer. My current code looks like this: Folder.multi_search(@search_query, [Myfile]) I noticed in the API you can
2006 May 26
1
multi_search will not work
I am trying to get multi_search to search across multiple models. I have the following: class Drug < ActiveRecord::Base acts_as_ferret :store_class_name => true end class Target < ActiveRecord::Base acts_as_ferret :store_class_name => true end and I am trying to query via: @drugs = Drug.multi_search(params[:query], [Target]) But I get no results. If I go: @drugs =
2006 Aug 19
11
Need help with multi_search
I have been trying to use multi_search to search accross multiple associated models, but I have had no luck at all. I have scoured the net and this forum for all similar posts, but none of them contain enough code for me to get it to work. I am successfully able to search individual models, and then display the results without a problem. I have the following 2 models, Product and Component.
2007 Mar 19
7
Many index files
I''m using acts_as_ferret and have indexed a model with acts_as_ferret :fields => [:name, :ascii_name, :alt_names], :single_index => true. Now in the index directory more than 95.000 files are generated! The number of tuples I''m indexing is approx. 86.000. I can''t remember this from earlier ferret/acts_as_ferret versions where I''ve indexed millions of
2007 Apr 16
5
AAF: merge search results
Hi, I have a user model that has a couple of other models(like street address, tasks). suppose User has a name field Address has a state field. so I want to provide a detailed search form each field in the user and its related models can be specified. Suppose I have a user that has a name "california", and that user has a address with the state field being "california" as
2007 Jun 24
6
I only want one type of model returned from a multi_search
I am trying to use acts_as_ferret''s multi_search to search across multiple models, but i only want it to return one type of model. for example i have a page that lists out people. on this page it shows email addresses and phone numbers. I want to be able to search by any fields directly from the person model and search the fields from the email_address and phone_number models, but I only
2006 Oct 14
9
How can I do my own search limits?
I''m trying to add a way to query across associations for a model in acts_as_ferret. Say I have a model A and it has a relationship with model B. Like say a Book has many pages. I want to search across the pages of the Book and produce a list of unique books who''s pages match the terms. So if I have a page that hits then I will add that book to my list of results. Right
2006 Oct 10
2
Ferret returning too many results
Hi, I just upgraded from acts_as_ferret 0.2/Ferret 0.9.x to acts_as_ferret 0.3/ferret .10.9, and i''m getting a strange behavior: searches are returning far too many results, most of them superflous. i''ll paste in my code below, it''s pretty simple. i''m googling like mad, and going through both the source and the forums, and having trouble finding what could