mySQL
mySQL macht selten was man erwartet, einige Sonderfälle scheinen absolut willkürlich zu sein. Dazu gehört die Verwendung von NOW() oder CURRENT_TIMESTAMP in DEFAULT-Werten einer Tabelle.
Look at the title and you're done. No need to add a text to this post if everything is said in the title. Not really? France is too small to hold half of the world's population? No way! My computer told me that 4.294.967.296 people live in France - and computers don't fail, you know?
Heute wurde mir eine kurze Frage gestellt:
Wir wollen in Richtung DB Slaves gehen, um die Hauptdatenbank zu entlasten. Ich würde gerne aus Deiner Sicht erfahren, wo Probleme auftauchen können.
mySQL clients tend to loose their connections from time to time and DBD::mysql could reestablish the connection automatically if it's lost using the mysql_auto_reconnect DSN connection string parameter - creating other problems.
Früher war die Sache einfach: Eine Textdatei oder später ein tie-Call und die Daten waren gespeichert. Heute kämpfen verschiedene Datenbanken um die Vorherrschaft - aber eine wirklich gute Option scheint es nicht zu geben, man kann nur das kleinste Übel wählen.
SELECT-INSERT-UPDATE - Kombinationen sind unzuverlässig, die Gefahr eines doppelten Datensatzes der eigentlich einmalig sein sollte, ist zu groß. Die Alternativen funktionieren aber auch nicht immer, denn mySQL verhält sich inkonsistent.
I'm using the WordPress plugin StatSurfer for quick dashboard statistics, but it's getting slower and slower while my blog is getting older.
SQL has some drawbacks, the worst one might be the SQL injection chance. There are many ways to avoid them but few of them are really working, one of them is using bind values by replacing all values by ? and passing the real values at execution time.
mySQL servers have their own mind and sometimes just disappear. They go away from a client leaving it alone if the complete server is dying, if a client is doing unexpected things and sometimes even without any known reason.
Es gibt Tage an denen man besser gar nicht aufgestanden wäre und es gibt Tage an denen es ganz gut war, doch aufgestanden zu sein, die letzten fallen in eine der beiden Kategorien.
Da schreibt man ganz ahnungslos an einem Blog-Post und plötzlich ist der Strom weg. Nicht bei mir, nein beim Server. Der Schock kam nach dem Reboot: Alle Blogartikel weg! Hilfe!
mySQL Date Bug: `date` >= '2012-03-01 00:00:00' is not the same as `date` >= '2012-3-01 00:00:00'
Mär 04
I'm loving it! Really, mySQL is an interesting creature. It's full of surprises and you never know what it'll do. There seems to be a date bug which took me only about an hour to find.
SQL hat viele Nachteile, aber einer der größten ist die Unsinnige Aufteilung zwischen der Erstellung und Veränderung eines Datensatzes. mySQL macht es dem genervten Programmiere mit MyISAM auch nicht leichter, denn Row-Locks oder Transaktionen werden nicht unterstützt. Aber ich schweife ab...
Huston, we have a problem. Our company's headquarter isn't in Huston, but anyway... we got inconsistent data between some mySQL tables. There is a cron job fixing such problems but usually only very few records need assistance, much less than 10 a week. Updating the script to find the newly discovery differences was less than a hour, but running it turned out impossible.
"Never change a running system" ist einer der Pfeiler, auf denen die IT-Welt erbaut ist. Jeder der schon einmal mit einem Computer zu tun hatte weiß, dass sich dieser Grundsatz nicht immer befolgen lässt, so auch heute Morgen.