I really don’t get it, why almost each post or article that I find about Ruby or Ruby on Rails or any gem says that this is what I really need and that this is awsome? This word seems to be so much devalueated in the Rails community. There everything is awesome. Why? Yea, I know, because it is… (regardless Rails is so slow, yea, I remember, that doesn’t matter, just buy more hardware).
Merry Christmas
perl -MCPAN -e 'install Acme::POE::Tree' perl -MAcme::POE::Tree -e \ 'Acme::POE::Tree->new()->run()'
Posted in programming.
– December 27, 2009
Are SQL Database Joins So Bad?
Last time on many forums there were endless discussions about database joins that they are very bad, very unefficient and terrible and the best is to avoid them. Generally that’s not true and I’ll try to show this here (taking some small 10 million records tables as on one forum was suggested).
Posted in programming.
– November 12, 2009
Why Ruby on Rails Migrations Don’t Work
Ruby on Rails Migrations
Migrations in Ruby on Rails provide some nice faetures for manipulating database structure. It is used mainly for two reasons:
- this is a nice way of keeping database structure changes
- you don’t need to know SQL
- the generated SQL code can be used for many database engines
The first point is OK (this is a must, you really should keep such a track of database changes). The second would be nice…. but that simply doesn’t work. I don’t think that not knowing SQL is such a huge advantage. Knowing SQL is really a need when you write some database software using relational databases.
Posted in programming.
– October 5, 2009
PHP Funny Behaviour
Today I found a small example of a php code that reminded me the endless battles between ruby/python and php folks stating how bad the php is. Well… let’s see the small example:
<?php
$ee = new e();
$ee->x();
print_r($ee);
class e
{
function x()
{
print "run x()\n";
}
}
running this returned no error, but instead the output is like this:
run x() e Object ( )
Yea… it seems that’s quite normal in the PHP world to instantiate an object of a class that is going to be declared later. And what’s more, the object is quite good
wonderful.
Posted in programming.
– September 16, 2009
Another misleading “PostgreSQL vs MySQL review”!!!
Yea… I wanted to write something as soon as I stop laughing from THIS but I think that reading this comment should be enough.
– August 31, 2009
The Worst Database Design
Let’s create tables… like this:
CREATE TABLE A
(
ID PRIMARY KEY
...
);
CREATE TABLE B
(
ID PRIMARY KEY
...
);
The whole idea is that (due to some reasons that I don’t remember) there is one-to-one relation between those two tables (A.id = B.id). One-to-one relation is not quite normal and should be avoided (avoided means don’t do that unless you know what you’re doing). The first table looked like this:
Continued…
Posted in database.
– August 25, 2009
Fail
A proper use of databases means using proper types, otherwise you just got some terrible database structure and data that doesn’t fit anywhere, like here:

Posted in programming.
– August 24, 2009












