Today, everybody is blogging “The Horror Coding Stories.” I didn’t plan on that, but then I thought that this is a perfect horror story (reposted from my personal blog).The context: me working at one of the first joint ventures in Russia in 1990s.
At the end of December, John went back to the US for Christmas. I was still working at that “it’s great!” project and on my makeshift database. And I came up with something cool. Something I was very proud of.
I did most of that work at home because it was time around the holidays. Although I did have a modem, that was before the times you could email a bulk attachment, so usually, I would compress my code with tar command and copy a .tar file to the diskette, and take this diskette to the office.
The next day John should have to be back, and I was anticipating my triumph. At about 9 PM, when kids were already long asleep, I started to make my final .tar file.
Nowadays, even some of the younger IT people might not know what the tar command does, yet along those of…
View original post 271 more words
Dear fellow Chicagoans! I just shared a LinkedIn post by 2ndQuadrant – the Early Bird registration for 2Q PG Conf ends on November 2!
It is going to be the third year of this conference coming to Chicago, and I can guarantee it will be even better than before. There are several reasons for that.
First, we are back to W hotel in the Loop, which is a very convenient location for those of you who work in Chicago and commute from the suburbs – very close to both Union Station and Ogilvie.
Second – there was a record number of submissions, and the best of the best were selected to be presented.
Third – guess who will be presenting the Ultimate Optimization Training?! Yes, your’s truly.
Now add to this list all of the advantages of a local conference. No airfare. No hotel charges. No travel time. Perhaps, if it would be up to you, you would not mind a getaway:). But I can guarantee that your manager would love an idea of sending you to the local conference, rather than to San Francisco!
And now, I have a world for Chicago PUG members. As a reminder, we are going to have a very special meetup on November 12: Magnus Hagander and Devrim Gündüz will be presenting! Those are two great reasons to attend in November, but there is one more: we are going to reveal a special discount code for Chicago PUG members.
Please register early for both of these exciting events!
Last week I had the first acceptance of my paper to the real Computer Science conference for a very long time (since 2015!). Many things make this acceptance very meaningful for me.
First, as I said, it’s the first one after four and a half years.
Second, this is my first acceptance for the scientific conference since I joined Braviant Holdings. When I spoke at ICDE 2016, I was already with Braviant Holding, but the work was done, and the paper was submitted during my Enova tenure.
Third, the topic of the paper is ORIM, which is very difficult to sell to both the academic community and industry alike, and we already had two rejections of the earlier version of this paper.
And the last – this is the paper Boris and I submitted together since I can’t remember how long (I want to say – since 1995 :)). OK, the first accepted paper together:)
We will be presenting at the SOFSEM 2020 conference in January. So yes, this is also my birthday present 🙂
The other day, it was brought to my attention that I shared this post directly on LinkedIn, without posting it on the World of Data. For the benefit of my follows on the WP platform, I am going to share it one more time, and also add some comments.
The blog post (The Lack of) Postgres in Academia is an extended version of my earlier post in the World of Data on the same subject. I am keeping returning to this topic because I see the consequences of its neglect.
I think that way too often, the community is focused on the current Postgres users and does not pay enough attention to our future base. And I am happy that Boris will have an opportunity to talk about this problem at the 2QPG Conf in Chicago.
More thoughts are in the blog post referenced above. Please read and share 🙂
I’ve been thinking for a while how to name our methodology of data exchange between databases and applications. Several years ago, we came up with the term HDAT – Holistic Database Application Tuning.
This term didn’t get much recognition, partially because I didn’t really like it myself. It is pretty vague and implies that the subject we are talking about is something “nice to have” rather than entirely new technology.
In an attempts to highlight the most important feature of this technology – the fact that it eliminates a need in any ORM – I came up with the term which I am going to introduce today: NoRM.
The letter ‘o’ stands for both ‘No‘ and ORM, to avoid double ‘o’ and any possible associations with “Noom”:). Also, it highlights the fact that this approach is natural, that this is “a new norm.”
From now on, I am going to call “this JSON thing” a NoRM approach or NoRM technology.
How do you feel about it? Do you like this term? Will you use it?
I suppose I am not the only person facing this problem. From time to time, you come across some report which is running very slow. Or just a stand-alone SQL statement, which somebody in your company needs to execute once a month, and they might not even remember who wrote it. And you look at 200 lines of code, and think – how I can even start to optimize it?
It usually helps if a person who wrote the code is still around. Even better, if this report was written just recently and the requirements are still fresh in people’s minds. Still – what would you do, if you have very limited time, very convoluted SQL, and you need to figure out how to make it better so that it won’t block ten other processes?
For a while, I’ve been trying to come up with simple guidelines for report writers, which would help to ensure that their reports perform decently without anybody spending ten times more time. It turned out that a very short list of rules can cover pretty much all the situations. We’ve been using these guidelines for a while now, and I am pretty happy with the results. Here is the list:
- For each report, figure out whether it is an “exception” report or a “summary” report. Exception means that we are looking for some errors, for abnormal execution. Such reports should return nothing if everything goes normally. Summary means that we want to process a large number of records and calculate some results, something like quarterly earnings.
- If a report in question is an “exception report,” define the criteria for the exception (what makes this report an exception). Make sure there is an index that can be used to select rows based on this criterion and make sure that this criterion is applied first in the execution plan.
- If a report is a summary, look for a way to update it incrementally. Make sure that there is an index to facilitate this search (most often, the increment will be by the time last updated, and this field should be indexed).
If you can find an example of the query, which does not fit into either of the categories and/or can’t be optimized using these rules – let me know 🙂