aspose file tools*
The moose likes JDBC and the fly likes How Google and other websites search faster Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "How Google and other websites search faster" Watch "How Google and other websites search faster" New topic
Author

How Google and other websites search faster

Piyush Garg
Greenhorn

Joined: Feb 09, 2005
Posts: 2
How Google and other search engines search faster ,
i try a database containing 75000 records that takes a long time to find
Is there any method for
send the code snippet or algorithm or concept
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

I can't claim to know anything about how Google builds its search collections - but I do know that one of the keys to its speed is it uses the world's larges Linux cluster.

The normal route to speed up queries is to add indexes to the fields you search on. Of course your query could just be poorly written - if you post more details perhaps people will provide critique.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Loren Rosen
Ranch Hand

Joined: Feb 12, 2003
Posts: 156
Of course the other, less common thing to make queries faster is to add parallelism, and it's likely Google is doing that too.
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 30938
    
158

Piyush,
Welcome to JavaRanch!

A query for a few rows in 75000 should take less than a second. An index would really help you out here. I've done queries on millions of records without noticeable performance.

It also depends how many records you need to match in the result. A query for 10 rows in a 100 million records (with a proper index) is going to be much faster than a query for 10,000 records out of a million. The less rows the query has to return, the less disk accesses it needs to make. In addition to the things already mentioned, this is something that works in Google's favor. They only need to return one page of results at a time. If you do a query and page through the results, you'll notice that the total number of rows gets more refined over time. The initial "page 1 of 20" is an estimate.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How Google and other websites search faster