Data blog — MySQL RSS



Installing Docker for Windows

The post covers installation process of the Docker for Windows client, a utility that allows to run and manage docker images on the local machine. Docker images can be used to facilitate component and regression testing and are very important tool in the hands of a developer.

Continue reading



Ranking of database engines

So it is January again and it is time for various trend reports and market share. Portal db-engines.com publishes, among other interesting content, periodic reports showing popularity of DBMS engines on the market. There is a number of factors taken into account, best described here. It is important to know that the report does not show the relative share of particular DBMS on the market, but rather its popularity among developers really.   What is striking though, that there are three leading technologies in terms of popularity - Oracle, MySQL and SQL Server. They are quite close to each other and quite apart from the fourth one - PostgreSQL. When you look at the historical trends chart, you can see that...

Continue reading



Unit testing for databases

Database applications can - and should - benefit from unit tests, but it is surprising how rarely database code is covered by such tests. One of the problems I suppose is with the fact that it can be pretty tricky to write an isolated test that does not modify the state of the system, so it is fully re-runnable and yields the same results each time. Martin Fowler wrote a good article discussing the unit tests concept - well worth having a look! Even if you decide not to implement unit tests for your stored procedures or queries, you can still implement them to ensure that the coding standards are observed. You can use unit tests to check naming conventions...

Continue reading



NoSQL or SQL?

The article focuses on these two database technologies, but in fact it can be extended to the whole realms of RDBMS and NoSQL databases. Certain aspects of both domains can be considered as advantages or disadvantages, depending on the point of view and particular business case. The flexibility of schema in MongoDB is appealing to teams who implement applications dealing with unstructured data. The strictness of schema definition required by relational databases can be beneficial when the application needs to ensure that the data quality meets certain requirements.

Continue reading



Enum data type in MySQL

While investigating features of MySQL database engine, I came across an interesting concept: the enum data type.   The enum data type allows for defining static data ranges that can be used as values of certain attributes. These ranges typically are quite small - for example marital status consists of 'Married', 'Single', 'Widowed', 'Divorced', 'N/A' . These five values can be encoded as an enum data type column. For example, we can define a table in the following way. create table Person ( FirstName varchar(50) not null, SurName varchar(50) not null, MaritalStatus enum ('Married', 'Single', 'Widowed', 'Divorced', 'N/A') not null ); Please note this is a very simplified code. Enum in MySQL has a certain feature - the values in rows...

Continue reading