One way to deal with anxiety

Whenever it comes to some sort of a test or exam, I start to have this feeling of worry and anxiety. It doesn’t matter how well I’m prepared - I still have it. And, of course, it affects my performance not in the best way.

A few notes on PHP exceptions

There are several practices, that I found myself using over and over again while working with PHP exceptions. Here they are.

Atomic change of an index in MySQL

Imagine you have a composite index on four columns, and you need to remove one column from the index. The obvious solution would be to re-create the index:

DROP INDEX idx ON test_table;
CREATE INDEX idx ON test_table (column1, column2, column3);

Split file in chunks without breaking the sequence with GAWK

Today I came up with a task for myself, mostly for fun, but it also has a useful application. I have a dump of some MySQL table in csv, it’s ~500K records. The data will be loaded into Neo4j, though I want to speed up the load and be able to parallelize the process. Of course, I can make it in any programming language, but I decided to practice with Linux shell commands and to use gawk.

Broken code theory

I have recently come across Broken windows theory article. It is a criminological theory which addresses the problems of urban disorder, vandalism and anti-social behavior. The theory states that:

Liquid engine for PHP

I’ve just finished working on my fork of the Liquid template engine.