Thuva, I really appreciate your reply. After endless hours of googling, and trial and error (best tool for learning), I think I figured it out. I am going to post a blog article, and update this thread once I have each step outlined. From that point I would love feedback so I know I am doing it properly.
I will work on documenting everything so at the very least it will help someone else down the road. Thanks! Chris On Apr 25, 8:40 pm, Thuva Tharma <[email protected]> wrote: > Hello Chris, > > It's hard to give a solid example without knowing more about Account > and Name models. You need to tell us the names of the fields in your > models as well as what fields you want to search on. > > Take a look at the code in this pastie:http://gist.github.com/101856 > > I hope that will give you a good starting point. I assumed that you > want to search on account number, account description, name, and > address. You will have to change the field names (i.e. account_number, > account_description) to match the fields in your models. > > -- Thuva Tharma > > On Apr 25, 2:17 pm, internetchris <[email protected]> > wrote: > > > > > Ok, so can I simplify my request?? I really need help. Can someone > > point me to the correct "function" to use so I know where to start? I > > simply want to have data from 2 models show up in my search results. > > If I could at least get the function I could probably hack my way > > through it. > > > Thanks! > > > Chris > > > On Apr 24, 10:56 am, internetchris <[email protected]> > > wrote: > > > > Hey Everyone, > > > > I am new to rails and Thinking Sphinx. I tried to use UltraSphinx > > > because the "Advanced Rails Recipe" book had an example, and I'm not > > > good enough yet to gin up my own code. I was able to get it to work, > > > but when it came to my harder questions there didn't seem to be any > > > support community out there like this one. So humbly I come back and > > > want to say "Good Job Pat" , group is a great resource, and it > > > underlies the fact you want to make this plugin better. > > > > With that said, can someone point me to a code example that does the > > > following... > > > > I have 2 models "Account" and "Name". > > > > Account has_many :names and ... > > > Name belongs_to :account > > > > I want to place search form in my Application template, and when it > > > searches I can search both models, but more importanly I can display > > > results from both models. My results view is "Results.html.erb" > > > > Example of the view.. > > > > Account# | Account Description | Name | Address > > > > Account#, and Account Description are stored in my Account table, and > > > Name and Address are stored in my name table. > > > > Any articles or codes examples would be helpful. If someone would be > > > willing to work with me on my specific example I would be willing to > > > compensate them for their time. I'm not looking for free help, I > > > simply want some help on this. I am gonig to go through my project > > > today and take out all of the Ultrasphinx junk, and get it back and > > > running on ThinkingSphinx. It's so painful to learn something new! > > > > Thanks! > > > > Chris > > > [email protected] --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Thinking Sphinx" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/thinking-sphinx?hl=en -~----------~----~----~----~------~----~------~--~---
