lunatechian (lunatech-ian)

one relating to, belonging to, or resembling lunatech

Happy Holi at Stanford, California, USA!

Holi is one of my favourite and I really love all aspects of it - colours, the burning of the bonfire the day before Holi (Holika Dahan), Bhang and the food! I had not had a good Holi celebration after I moved to Bangalore (2005).

However, I had a GREAT Holi yesterday when I joined thousands of others from Bay Area in the Asha Stanford's Holi celebration. I had tons of fun coloring my wife, friends and random folks, having yummy food and enjoying a beautiful day in the sun.

We had planned to take the train to one of our friend's (N) place and then accompany him and his wife to the Holi celebrations. The day started at 8 AM and we had a hiccup when we missed our train to get to our friend's place. We had to wait another hour to catch the next train. However, things started looking better after this incident. We ran into another acquintance Of ours on the train station and they got on the same train as us. We passed them a few tips about which places to visit in San Francisco (they were on their way to SF for some tourism).

We got down at our station and N. came down to pick us up. We went to his house, chit-chatted for a while and then started off for the venue to Stanford.

I was expecting a jolly good time and that is what I got :-) . The holi was in full swing when we got there. One of the playgrounds had been cordoned off for the holi festivities. We took our tickets and jumped into the festivities. There were lots of colors and lots of people. After we had colored each other, we started putting colors on random people. After 30 minutes with colors, it was difficult to recognize each other. There were some dance performances by some Stanford groups. And then the dancing started. And then we put color on more random people. The festivities ended around 3 PM. We had some food and then we came back home. Back home, we had to scrub ourself for around 15 minutes to clean out the colors, but it was a minor hassle.

Overall, I had a very good time and I hope to go back to the Holi celebrations again next year.

Defined tags for this entry: , ,

optmizing ORDER BY in MySQL

A few days back we were trying to optimize a sql query that was using an ORDER BY clause. When we ran an EXPLAIN on the query, we saw that the query was Using filesort and Using temporary. Since this query was run quite frequently, there was a benefit in optimizing this.

I had been under the impression that if your query uses filesort and then has to use temp tables for sorting, you cannot do much to save the query. However, that is not the case. If you have an index on the column being used to do the order by , mysql will use that index for sorting. Of course, there are caveats to this, the most important one being

The key used to fetch the rows is not the same as the one used in the ORDER BY: SELECT * FROM t1 WHERE key2=constant ORDER BY key1;

Hence, if you have a query which requires to be sorted, and it is being run quite frequently, it makes sense to add an index on the column on which you are doing the sort.

Defined tags for this entry: ,

ILUG Bengaluru Meetup - Saturday 21st February 2009

Linux User Group, Bangalore have a meetup at the ThoughtWorks office on Saturday 21st February 2009, 4:30 PM onwards. The details of the meeting are here. There are 2 talks lined up- "Introduction to the Android Platform" and "Device Mapper - How it works and why you should be using it". And there will be a key signing party as well.

Go, check it out and help revive the LUG meetings at Bangalore.

Defined tags for this entry: ,

Un-minimizing apps in Mac

This tip saved a lot of pain.

If the application you're switching to has windows that are minimized, you can unminimize them by holding the option key, then letting go of the Cmd key.

7 things

Thanks to Lig for tagging me. 7 things you may or may not know about me:

  • I started a company, along with my friends, after I passed out of college. We just made one sale. Our project was made using mysql-3.x and VB. The implications here are - I have worked on VB, I know how to make mysql & VB work together and I know how to generate nice reports with the VB report generator.
  • I have worked in Goa. In my opinion, Goa is the best place in India that I have ever stayed in.
  • I used to own a Bullet 350 CC motorcycle. It is a great piece of machinery and in fact, it is the only vehicle which I DON'T consider to be a part of the "Get-me-from-point-A-to-B" class
  • spo0nman referred my name to Yahoo! and he gave me the boost of confidence when I was unsure if I am good enough to be even interviewed by them.
  • When I joined Yahoo!, I had to move from Delhi to Bangalore. However, the truck transporting my household stuff was burnt on its way to Bangalore. I had to start with a clean slate.
  • I had to clear many hurdles to get married. It was a constant 2 year struggle with my family, my wife's family and random circumstances. However, the end result was well worth the struggle.
  • I sometimes cry at movies and I find those sort of movies emotionally draining.
Defined tags for this entry: