3 ms·
"Obvious" for you, maybe for a general AI, but not to the DBMS. What if such field is a blob with a uncompressible 12mb blob of a image of a index card? What
by ElectricalUnion 4y ago
"Obvious" for you, maybe for a general AI, but not to the DBMS.
What if such field is a blob with a uncompressible 12mb blob of a image of a index card?
What if indexing them would waste several TBs of RAM? That is not a good default.
On a more realistic scenario, it is reasonably rare that you will only ever search using the PK, and no other constraint, so in a way is a wasted default index.
- ape4 4y agoGood point, make that only apply to fixed length chars (not varchars). I think JOINs use indexes which are often done on the primary key. https://www.mssqltips.com/sqlservertutorial/3207/make-sure-all-join-columns-are-indexed/ https://www.mssqltips.com/sqlservertutorial/3207/make-sure-a...