Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Autocomplete slow on Heroku
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  5 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Sunny Beach  
View profile  
 More options Jan 25 2010, 11:20 pm
From: Sunny Beach <sunnybeach1...@gmail.com>
Date: Mon, 25 Jan 2010 23:20:51 -0500
Local: Mon, Jan 25 2010 11:20 pm
Subject: Autocomplete slow on Heroku
I have a small app that has a single Jquery Autocomplete field. It
seems very slow and spotty (not returning all the results it should)
on Heroku. It does work but not very well.

Is this due to the differences in databases between here and Heroku?
The call for the autocomplete is:
ProgramName.find(:all, :conditions => ['name LIKE ?', "%#{params[:q]}%"])

Is it due to a query limit (I am the only person using it at the moment).

Any ideas?

Thanks,
Sunny


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sunny Beach  
View profile  
 More options Jan 26 2010, 10:20 am
From: Sunny Beach <sunnybeach1...@gmail.com>
Date: Tue, 26 Jan 2010 07:20:22 -0800 (PST)
Local: Tues, Jan 26 2010 10:20 am
Subject: Re: Autocomplete slow on Heroku
I have narrowed down the problem to capitalization. If the query
string matches up (exactly) then all is well.

BAD:
http://content-tracker.heroku.com/program_names.js?q=inter

GOOD: (finds three "International..." programs)
http://content-tracker.heroku.com/program_names.js?q=Inter

I have not been able to figure out how to fix this.

You can see the full list of programs (only 20 currently):
http://content-tracker.heroku.com/program_names.js

Sunny

On Jan 25, 11:20 pm, Sunny Beach <sunnybeach1...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Nick Quaranto  
View profile  
 More options Jan 26 2010, 10:23 am
From: Nick Quaranto <n...@quaran.to>
Date: Tue, 26 Jan 2010 10:23:00 -0500
Subject: Re: Autocomplete slow on Heroku

Are you using MySQL to develop locally instead of Postgres? MySQL considers
LIKE case insensitive, you need to use ILIKE on postgresql to get the same
behavior.

-Nick

On Tue, Jan 26, 2010 at 10:20 AM, Sunny Beach <sunnybeach1...@gmail.com>wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Sunny Beach  
View profile  
 More options Jan 26 2010, 10:29 am
From: Sunny Beach <sunnybeach1...@gmail.com>
Date: Tue, 26 Jan 2010 10:29:14 -0500
Local: Tues, Jan 26 2010 10:29 am
Subject: Re: Autocomplete slow on Heroku
Many thanks, that seems to make everything work!

Sunny

ps. yes, I should be using postgres locally.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Max A  
View profile  
 More options Jan 26 2010, 10:57 am
From: Max A <nanode...@gmail.com>
Date: Tue, 26 Jan 2010 07:57:38 -0800 (PST)
Local: Tues, Jan 26 2010 10:57 am
Subject: Re: Autocomplete slow on Heroku
Well...there's a good reason MySQL is generally more popular --
Postgresql may be faster/more features, but boy is it a pain to
configure locally (at least last I checked), compared to MySQL where
it's basically install, set root password, and you're golden.
(Obviously you need to create non-root users, but that's
straightforward)

On Jan 26, 7:29 am, Sunny Beach <sunnybeach1...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »