Indexes and multi column primary keys
- by David Jenings
Went searching and didn't find the answer to this specific noob question. My apologies if I missed it.
In a MySQL database I have a table with the following primary key
PRIMARY KEY id (invoice, item)
In my application I will also frequently be selecting on "item" by itself and less frequently on only "invoice". I'm assuming I would benefit…