Databases use indexes to speed up lookups, but understanding how queries scan data is just as important. COUNT(*) is an aggregate that returns the number of matching rows.
Count how many comments have been left on the post titled 'First Post'. Join posts and comments, filter by title, and return the count.
Databases use indexes to speed up lookups, but understanding how queries scan data is just as important. COUNT(*) is an aggregate that returns the number of matching rows.
Count how many comments have been left on the post titled 'First Post'. Join posts and comments, filter by title, and return the count.