One of the powerful features of Lightroom (and incidentally, one of the reasons why I started using it) is its ability to read the EXIF data from each photograph, for photographers to be able to sort images easily and stay organized, and to quickly find specific photographs without going through thousands of pictures. Lightroom stores its catalogs in a database, which is designed and optimized to index all relevant fields such as Camera type, Lens type, Aperture, Shutter Speed, ISO, Keywords and Collections, in addition to storing information about every single picture (note that the pictures themselves are not stored within the database). This index is used by Lightroom extensively – every time when you access an image or work with “Collections” and “Keywords” to tag your photos, this index is read from and written to. This database is also the reason why Lightroom gets much slower overtime as you add more and more photographs to it, since it stores so much information about every single photo.
At the end of each year, I go through my Lightroom catalog to see my “photo statistics”. I do it through the “Library Filter” feature on top of Lightroom’s “Library” module: