May 2018
Intermediate to advanced
576 pages
30h 25m
English
Consider one more scenario: an application runs a huge number of small lookup queries. This can easily happen with modern Object Relational Mappers (ORMs) and other toolkits that do a lot of work for the programmer, but at the same time, hide a lot of what is happening.
For example, if you define an HTML report over a query in a templating language, and then define a lookup function to resolve an ID inside the template, you may end up with a form that performs a separate, small lookup for each row displayed, even when most of the values looked up are the same. This doesn't usually pose a big problem for the database, as queries of the SELECT name FROM departments WHERE id = 7 form are really fast when the row for id = 7 is in ...