Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
rimantas
· 15y ago · 0 comments
I lived in constant fear of forgetting a WHERE clause.
For those in constant fear:
http://dev.mysql.com/doc/refman/5.1/en/mysql-tips.html#safe-...
Comments
[–]
idlewords
15y ago
Ha, I half-remembered this existing and tried to Google my way to it, but to no avail. Thanks so much for the pointer!
[–]
jtbigwoo
15y ago
In a huge database, even a SELECT with no WHERE clause can tie up considerable resources.
[–]
neilk
15y ago
--i-am-a-dummy also limits the number of rows you can SELECT or JOIN.
[–]
dasil003
15y ago
You can kill it though, use SHOW PROCESSLIST
[–]
dools
15y ago
I always write my WHERE clauses first whenever I do anything on a live dataset.
[–]
SupremumLimit
15y ago
I always had a rule to do everything inside a transaction. Having to commit a transaction gives you just enough pause to double check what you've done.
[–]
shii
15y ago
It's funny because I bookmarked this on pinboard.in