Apart from creating indexes on columns that are retrieved often, and doing SELECT col1, col2, col3 FROM tbl instead of SELECT * FROM table, what else should I know about designing databases for scalability / fast performance?
Asked
Active
Viewed 131 times
0
Ali
- 261,656
- 265
- 575
- 769
-
1Some nuggets here: [database-development-mistakes-made-by-application-developers](http://stackoverflow.com/questions/621884/database-development-mistakes-made-by-application-developers) – p.campbell May 12 '11 at 17:03
4 Answers
3
There is tons of stuff, you need to know, small sample
When to use partitioning
make tables as narrow as possible so that you can fit more rows per page
how to minimize locking and blocking
sharding
disk IO subsystem (raid 5 or 10, SAN or HDD)
making queries SARGable so that indexes will be used
Explain plan
Using the correct data types
Difference between a seek and a scan
SQLMenace
- 132,095
- 25
- 206
- 225
2
You might find this thread interesting:
Database development mistakes made by application developers
Community
- 1
- 1
Denis de Bernardy
- 75,850
- 13
- 131
- 154
1
You should know:
- how order affects JOINs.
- how to use EXPLAIN PLAN.
- how certain kinds of WHERE clauses cannot use indexes and force table scans.
duffymo
- 305,152
- 44
- 369
- 561
1
- Learn how to use explain to understand the way MySQL is processing your query
- Learn how to use Slow Query Logging
- Think about partitioning/sharding
- Consider the database engine that you're using
Mark Baker
- 209,507
- 32
- 346
- 385