concept database query in category rails

appears as: Database query, database queries
Rails 3 in Action

This is an excerpt from Manning's book Rails 3 in Action.

Database queries are often the bottleneck in the application because they may inadvertently be performed in excessive amounts, or they may not be indexed in the correct manner. You saw in the beginning how to implement eager loading for your queries so that rather than doing more requests than necessary, Rails will load all the necessary objects in a second, separate query.

16.2. Database query enhancements

What would you do without database queries? Well, you’d have a boring application, that’s for sure! But it’s database queries that can be the biggest bottleneck for your application once it grows to a larger size. Having a page that—in the beginning—only ran 5 queries and is now running 100 on each request will just not be webscale.