My copy of MySQL Workbench doesn’t play 100% nice with my MariaDB install, so I checked out the Database Workbench software recommended by MariaDB and in the end I downloaded a trial version. It runs okay under Wine, so gonna check it out.
Category Archives: Database
Window Functions Overview
Reading about Window Functions.
From What’s SAP?:
A basic installation of SAP has 20,000 database tables, 3,000 of which are configuration tables.
Things You Should Know About Databases
This one popped up in my feed today: Things You Should Know About Databases. My favourite quote was this one:
The SQL standard defines 4 standard isolation levels these can and should be configured globally (insidious things can happen if we can’t reliably reason about isolation levels).
It’s so important to know what isolation level is applicable to your connection/transaction.
The Database Relational Fuckup
In his book The Database Relational Model on page 25 Date says:
Here I would just comment–here comes the hindsight once again–that if as suggested earlier the database is to be regarded as a (correct!) logical system, it must never be allowed to contain any inconsistencies, at least from the user’s point of view. In other words, “remedying inconsistencies” needs to be done on an individual statement-by-statement basis (not even on a transaction-by-transaction basis). See reference  for further elaboration on this point.
Reference  is then:
C. J. Date and Hugh Darwen: Foundation for Object/Relational Databases: The Third Manifesto. Reading, Mass.: Addison-Wesley (1998). A second edition of this book, under the revised title Foundation for Future Database Systems: The Third Manifesto, is due to appear concurrently with the present book.
I think Date did a lot of harm with this comment. The classic example of a transaction is taking $100 from my account and depositing it in your account. So there’s one statement to take the money out, and another statement to put the money in, and after the first statement but before the second statement the database will always go through an invalid state. If RDBMS integrity facilities were on a transaction-by-transaction basis we could actually use them, as they’re not we suffer. Either we need to do more work than necessary or we have to under specify our constraints, or some awkward combination of both.
Surrogate Key and Natural Key
In Database Design 25 – Surrogate Key and Natural Key the presenter Caleb Curry agrees with my view that if you expose your surrogate keys they become natural keys. See around t=5:00.
Codes for Trade
Today I discovered the UN Codes for Trade. It includes info about countries and locations, currency, etc.
The Connection Strings Reference
This popped up on HN today, looks handy: The Connection Strings Reference. Well, I thought it might be handy, but it doesn’t seem to support PHP PDO.
Entity Relationship Diagrams
Today I was reading about Entity Relationship Diagrams in Lucidchart. They have some notes on Entity-Relationship Diagram Symbols and Notation with their ER diagram tool.
SQL Query Stuck in Statistics State
I had this problem which is explained in greater depth over here.