Dynamic load data on scroll - dynamic

I am working on a web application, where we need to show more than 20,000 rows in a single page.
What is the best way to achieve this? As per requirements, we cant use pagination.
We are looking at options like Live Scrolling in Adobe Flex..is there any other framework that helps in doing this job efficient and easy?

I found this tutorial while surfing. i think this is just what you need :)
http://www.webresourcesdepot.com/load-content-while-scrolling-with-jquery/
cheers.

Related

Best way to implement autocomplete with sql

I know this question has been up before but that was like three years ago and that's a lifetime :).
I'm using the twitter-bootstrap typeahead for autocomplete against mysql db with php, it works good right now. But I hit the db with a query every key-event, it doesn't feel like a good solution for a large scale application.
What's the best aproach here? Im thinking about memcache, but this is a dynamic db that will grow, how do I make sure that new information in the db get's cached to? I'm open for suggestions.
On Feb 2013 Twitter released typeahead (is not the bootstrap one),
it is s a powerful opensource lib for autocomplete, and one of his feature is:
Rate-limits network requests to lighten the load
I suggest you to give try.
Useful links:
http://twitter.github.com/typeahead.js/examples/
https://github.com/twitter/typeahead.js
http://engineering.twitter.com/2013/02/twitter-typeaheadjs-you-autocomplete-me.html
For autocomplete it's possible use trigram matching.
Also you can use specialized fulltext search engines like Solr/Lucene or Sphinx.
Another alternative: switch to postgresql and use pg_trgm extension.

RoR: how can I seperate a page on my website into two large columns?

I want to make a vertical line going through the middle of the site and then have content on either side. How can I use CSS or ruby? to do this? I am not sure which one I would need and where I would put it. Also, what is the best resource for learning the syntax of the ruby on rails views/CSS stuff. It seems that rubyonrails.org doesn't have much documentation on that (they mostly explain the models and controllers)
I would suggest you start with something like: https://github.com/softmachine/rails-bootstrap
They provide a link to http://twitter.github.com/bootstrap/ which has plenty of documentation.
The next step, would be to ask a more specific question related to the exact problem you're having.
From your description it sounds like you need css, and depending on the nature of of the information you want to display, you might need to use ruby/rails to make it happen. Most likely, you could just use css.
see: http://jsfiddle.net/aTUq8/

Where should I read up on sorting posts in rails?

Just an open ended question - I'm using rails 3.0.9. I want to experiment with sorting systems. I'll want to start with a simple upvote/downvote system, and then try out more complex iterations.
However, I would want not to sort simply on upvotes/downvotes but provide a controllable skew for time (so that really interesting posts eventually give way to new ones).
Anyone have any suggestions on where to read about these sorting algorithms either generally or in rails(3)-specific sources?
Thanks everyone!
try meta-where meta-search in this project sorting was talked about using meta-search gem. i hope this helps

How can i chose different data templates for different items in listbox?

I know the question I am asking is normally not encourentered in business applications. However i have encourentered such a need today.
The photos in my listbox are coming from two sources :- One is offcourse from database and other is coming from facebook. I have the user's photo link using facebook C# SDK. Thus i need to have two different data templates as well as binding set up that way. How can i solve this problem? Oh! and yeah i don't want to put up two listboxes on screen and do patch work by putting one listbox exclusively for images coming from my server and other which are coming from facebook.
Thanks in advance :)
Was looking for the same thing since i heard that DataTemplateSelector was missing in Silverlight.
Came across this article that might help anyone else that is looking.
SLTemplateSelector

Lucene.NET Faceted Search

I am building a faceted search with Lucene.NET, not using Solr. I want to get a list of navigation items within the current query. I just want to make sure I'm pointed in the right direction. I've got an idea in mind that will work, but I'm not sure if it's the right way to do this.
My plan at the moment is to create hiarchry of all available filters, then walk through the list using the technique described here to get a count for each, excluding filters which produce zero results. Does that sound alright, or am I missing something?
yeah. you're missing solr. the math they used behind doing faceted searching is very impressive, there is almost no good reason to not use it. the only exception i can find is if your index is small enough you can roll your own theory behind it, otherwise, its a good idea to stand on their shoulders.
Ok, so I finished my implementation. I did a lot of digging in the Lucene and Solr source code in the process and I'd recommend not using the implementation described in the linked question for several reasons. Not the least of which is that it relies on a depreciated method. It is needlessly clever; just writing your own collector will get you faster code that uses less RAM.