Answers to Chapter 18

  1. "Disabling as many extensions as possible increases the speed of your scripts: true or false" True, but not massively. Each extension has to do some work each time a request comes in, but it's very minimal.

  2. "Adding indexes to every field in your table maximises the chance of top performance: true or false" False: overindexing is almost as bad as not indexing at all!

  3. "What is the difference between a DELAYED query and a LOW_PRIORITY query" DELAYED queries are not executed immediately, but are queued up until a sufficient number of queries is ready or a certain amount of time has passed, then are executed at normal priority. LOW_PRIORITY queries wait until no more reads are waiting.


Want to learn PHP 7?

Hacking with PHP has been fully updated for PHP 7, and is now available as a downloadable PDF. Get over 1200 pages of hands-on PHP learning today!

If this was helpful, please take a moment to tell others about Hacking with PHP by tweeting about it!

Next chapter: Answers to Chapter 19 >>

Previous chapter: Answers to Chapter 17

Jump to:


Home: Table of Contents

Copyright ©2015 Paul Hudson. Follow me: @twostraws.