In PostgreSQL 8.4 we got CTE – Common Table Expressions. Since then we have this great tool available, but apparently for some people it's still black magic. CuTE, but still magic. I'll try to make it a bit less magical, and more understandable.
Tag: primer
Window, window on the wall …
And maybe not on the wall, but instead in your SQLz, eating your data.
But a bit more seriously. Ever since PostgreSQL 8.4 we have window functions, but still I see people which do not know it or are wary to use it.
That's why I decided to write a piece on window functions. How they work and what they can be used for.
How I Learned to Stop Worrying and Love the Triggers
Some people are afraid of triggers.
Reasons for this are not really understandable for me, but I guess it stems from the fact that these are usually application developers, and not database admins. Or they encountered some kind of problem with triggers, and now they tend to think that triggers are inherently evil.
But they are not.
As virtually anything, triggers have some benefits, and some drawbacks. With a bit of thinking you can use them to do really cool things. But first you have to understand what exactly trigger is, how it works, and when to use which kind.
Continue reading How I Learned to Stop Worrying and Love the Triggers
“PostgreSQL: Up and Running” by Regina Obe and Leo Hsu
Around a week ago, I got mail saying that authors wanted me to have their book. For free. That's relatively important because getting things for free means you should pay for it in other way (that's my position, it was not suggested in any way in the mails). Plus – I generally never read technical books (really – I just don't), so there was no chance I would get it myself, if it wasn't gifted.
After some mails I got mobi version of PostgreSQL: Up and Running.
Continue reading “PostgreSQL: Up and Running" by Regina Obe and Leo Hsu