Vertica and K-Safety

So you probably know that I have been working with HP’s Vertica. I’m very glad that I had this opportunity to interact with something like this. The technology behind it is pretty new and immature and lacks the power of PL/SQL but the speed that it achieves through massive parallel execution of queries is simply amazing. I don’t know if you have heard of the term K-Safe or K-Safety. When I first heard it, I had no idea what it was. Then after going through some of the documentation I kind of got the point. ...

November 6, 2013 · 2 min · 382 words

Perl - Autovivification

When I first heard that term, I was worried. I felt ashamed of myself for not knowing it. After all I’ve been writing Perl scripts for almost 3 years now. And I still don’t know what that means. But finally I accepted that computer science is too vast to know everything about everything. You learn it as you get through it. So apparently: Autovivification is the name for what happens when you attempt to assign a nonexistant entry of a hash; Perl actually creates the missing hash entry for the key you specified. You might not have intended that to happen. But Perl does exactly that. I’ve recently seen a bug in my new team because of this very feature or curse of Perl. And it did take a long time for them figure out the root cause of the problem. Because Perl doesn’t complain when this happens. This is more of a logical error than a compile time or run time error. Hence too hard to find. ...

November 4, 2013 · 1 min · 190 words

Software Engineers should read this

I think as programmers you should read and understand this: http://martinfowler.com/ieeeSoftware/explicit.pdf From the expert in OOAD and related stuff - Martin Fowler.

October 14, 2013 · 1 min · 22 words

SQuirreL graphical user interface for Vertica

Hey guys, I tried out DBVisualizer earlier. I liked it and I have blogged about setting that up for your Vertica database. But it is expensive. I mean I can’t buy it for my personal use unless a company actually sponsors me. I’m a poor developer you see. So I searched for alternatives and I kind of liked SQuirrel SQL client. It is a java based open source SQL client which is pretty awesome. First you should go and download it to know what I mean: http://squirrel-sql.sourceforge.net/. ...

September 24, 2013 · 5 min · 1030 words

Vertica Query Performance Tuning - An introduction

Hey there, I guess you have been having a lot fun with your Vertica databases. I thought I’d share some of the things that I did to improve my query performance. Tables and Projections in Vertica In Vertica even though we access data through tables everything is stored in projections which are stored among nodes in various ways depending on the K Safety and the Segmentation options that we choose when creating the table. We can make modifications to these projections manually or run the Database Designer to generate projections for us. Sometimes to get the best performance we have to write query specific projections. ...

September 12, 2013 · 5 min · 915 words

DIR on VMS and display useful information

I don’t know if you have even heard of this operating system named OpenVMS by HP. Unfortunately or maybe fortunately I have had a chance to work on it. The operating system has a cool feature, file version is built into the OpenVMS file system. But the problem with this is that if you go into a log directory and list out files, the list could get really long. I was just trying to make it display things that I usually use on Linux. ls -lrt ...

August 7, 2013 · 1 min · 188 words

Vertica and its version - Find out using SQL

I was playing around with Vertica and my friend suddenly asked me what version of Vertica I was using. This was because he was trying to debug something and posted a question to guys from Vertica and they asked him that question. At my workplace we use the same Vertica cluster for development. It is a playground with a lot of restrictions. Without DB Admin access you can’t really explore much in Vertica. But yea we are trying to get the most out it despite all that. ...

June 24, 2013 · 1 min · 167 words

Exploring Vertica's INTERPOLATE predicate

Vertica has a special feature to join tables and fill in the last available values where values would otherwise be null. I had a similar use case and wanted to test how I could make the best use of it. I played with simple examples and got it right, but with a slightly more complex one, I was stuck or maybe I just couldn’t understand what was happening. So I posted a question at Stackoverflow ...

June 18, 2013 · 1 min · 75 words

Vertica - Calendar table with dates from a start date to an end date using analytical SQL

I had a problem creating a table with just SQL that is supported by Vertica. Most of the solutions that I came across online were using procedures. But after a lot of playing around and reading vertica documentation I found a solution to my problem. read more about the problem and the solution at Stackoverflow

June 18, 2013 · 1 min · 55 words

Bash v/s Cshell - Functions and their definitions - useful 'type' keyword

Hey if you have worked on Linux then you have interacted with bash. Maybe not. But it is mostly likely that your default shell is bash. I’m not surprised. I’m among the few people on this planet who regularly interacts with cshell also. Thanks to the kind of work I do. One great feature of bash that I miss in cshell is: Functions. Surprised? Cshell doesn’t support functions. It doesn’t have any concept of function. If you wanted to simulate a function, you have to write another cshell script that does what your function would do and define an alias that calls it. ...

June 9, 2013 · 4 min · 659 words