Wednesday, May 16, 2007

Google can't satisfy ...


This is really funny!. Copied from Matt McSpirit's blog. Another funny one is on Steve Clayton's blog.

Friday, May 11, 2007

Spidey spins his web again


gatorIndex: 3.5/5.0

Spidey-3 has officially(finally) arrived, shattering an assortment of records on its way to worldwide box office dominance.

But was the movie really that good Or did the success of spidey-2 make fans(like me) flock theaters in anticipation of yet another fantastic flick from Sam Raimi's stable.

Well if my opinion counts, the movie was not half as good as the second installment. And the ratings say critics agree too. It has a lowly 61% on RottenTomatoes and a B- on yahoo movies. Seems like I am not alone here.

My initial intention was to go watch the premiere show as I did for Spidey-2. Alas! sold out at AMC Mayfield, when I checked the Tuesday before release. So I advanced booked myself a Friday night 10:15 @ Fandango and eagerly awaited the weekend. BTW the premiere show for spidey-2 two yrs ago was a sell-out too. Back then, having arrived at the theater a little too late, I found myself staring at an unbelievably big screen. Proximity perhaps, first row to be precise. I mean honestly, who would expect such huge crowds for a Thurs night 11:59 show. I had to move my head around to capture all the action. In the end, well worth every penny.

The 10:15 show this time wasn't exactly a sell out. I could still see considerable empty seats from the view above.

After 2.5 hrs, I walked out the theater with a eerie feeling...did not enjoy the movie as much as I would have wanted to. Sammy as I see it, tried to cover too much ground, too little character development, lack of smooth flow in story, cheesy fan cheering and bash parties, convenient insertions(the kiss,butler). I think the kiss scene was inserted to just precipitate things a little faster, so that more of something else could be covered. Bad choice sammy!

Still the movie wasn't really that bad. Just that, the expectations were so high, It could not deliver at that level. This is one of those movies that I would have watched nevertheless. Giving credit where credit's due, the special effects were amazing.

Lot of sequels coming out this summer and these make my must watch list : Shrek the Third, Pirates of the Caribbean : At World's End, The Bourne Ultimatum, Harry Potter and the Order of the Phoenix.

Watch out for these this summer!

Sunday, April 29, 2007

Firefox is recommended browser

Videohybrid displays this message when you visit them on a browser other than Firefox. I have come across numerous websites that are the other way around. Never have I seen anyone put up a banner like this in support of Firefox. Amazing!

If you have ever read my previous posts, you know I am a big Firefox fanatic. There is so much value added stuff in Firefox that is glaringly absent in IE7. But If you are using IE7, this Find As You Type extension is a MUST HAVE and takes a lot of the pain off your surfing experience.

My browser right now is Grand Paradiso Alpha 1. Contributing my 2 cents to the Firefox community with user testing and crash reporting.

If you are wondering what Videohybrid is, it is one of those next generation video aggregators that make it easy to find you favorite shows, movies. It is illegal though as it streams videos from other websites that house illegal content like dailymotion. A post on techcrunch made it highly visible and brought with it unprecedented load and traffic that has seen the site go down more than once.

The point here is, I am happy to see such a banner, but would truly love to see a day where all browsers follow and implement common standards. Well, Thats still a long way away, made even harder by IE's majority share and Microsoft's own way of doing things.

Have you tried Coke Zero yet?


I am one of those guys who needs a constant supply of coke to keep going. I used to gulp down as many as 8-9 a day. I ABSOLUTELY love the taste !. But over time, all those calories and carbonated water started making me feel stomach heavy.

I unsuccessfully tried switching to diet coke or diet pepsi to at least cut down on the calorie intake. Ho diet coke is horrible and diet pepsi I can do with, but not for long. So I found myself coming back to coke again and again. Something in it.. the taste .. may be the caffeine.

With some restraint, I can now get away with 2 a day. Trident has really been helpful in this regard. I realized chewing Trident brings down my urge to grab myself a coke. So I find myself chewing Trident all day, spitting it out only to have lunch.

One of these days I watched the sue-coke-zero-for-taste-infringement commercials. They are really funny. Given the diet coke experience, I wasn't really looking forward to a rich taste...but to my surprise it was real close to coke classic. Well, you can't make it taste exactly like coke classic when it has only zero calories. It was close enough that I decided to give it a chance. So I have been training myself to Coke Zero and am officially switching from Coke Classic to Coke Zero, AT LAST.

Eventually, I would love to get away from the urge to drink coke anymore. So If you are looking for Coke-ness without the calories, Coke Zero is worth a shot.

Off to another Coke Zero and wilfing !

Saturday, April 07, 2007

SQL Short-circuit

This post looks at short-circuiting in SQL Server 2000/2005 and its caveats.

Consider a simple product search scenario. If the user enters something in the search box, you want to retrieve product results pertaining to the search text, otherwise you want to bring in all the products, effectively ignoring the parameter.Ideally you will page the results.

This is a typical example of Optional Parameters, requiring a Conditional Where Clause in your translation to SQL.

A simple SQL statement fails to capture this essential part of the problem domain and there seems to be no easy way to accomplish this. Most of the developers resort to using dynamic SQL, table variables with joins, If expressions or CASE Statements to accomplish this. Short-circuiting can come in handy in these situations and gives a performance boost that is worth investigating.

To illustrate that SQL does indeed support this feature, execute the statement below as indicated by Mark Cohen on his blog.

Select 1 Where 1=1 or 1/0=0

We indeed don't get a divide by zero exception reinforcing our claim that SQL Server does have short-circuiting support.

As Jeff points out, many of the CASE expressions can be converted into boolean logic and hence take advantage of short-circuiting.

Assume @CustomerID = -1 is the default value, indicating that nothing was passed in. Optional Parameters would generally be coded as one of these

Exec sp_executesql @YourDynamicStatement

(Or)
If @CustomerID = -1
Select * from Sales.Customer
Else
Select * from Sales.Customer Where CustomerID = @CustomerID

(Or)
Select * from Customer
Where
Case @CustomerID
When -1 Then 1
Else
Case When @CustomerID = CustomerID Then 1 Else 0 End
End = 1

(Or)
Select * from Customer
Where CustomerID =
Case
When @CustomerID = -1 Then CustomerID
Else @CustomerID
End

The equivalent boolean logic(with short-circuit) would be as below Where (@CustomerID = -1 or CustomerID = @CustomerID)

When @CustomerID = -1 , indicating that nothing is passed in, the right side expression is never evaluated.

As you can see, this is easily readable as well as maintainable.

Now if you look at the comments in Jeff's blog, a user complains that his short circuit doesn't work.
Select * from Northwind..Orders
Where CustomerID = CustomerID and OrderID > 1/(0*year(getdate()))

You would expect this statement to not generate a Divide By Zero exception, but it does. So Whats wrong here.

We found out, the short circuit works only if the expression is DETERMINISTIC. That is, if the engine can look at the expression and determine its truth value without having to run the query, then the engine short-circuits the statement, effectively ignoring the entire expression.

Eg.; The truth value of @CustomerId = -1 can be determined before hand and hence is deterministic.Similary are
Select 1 Where getdate()=getdate() and 1/0=0

Select 1 Where 1=1 or 1/0=0

Select 1 Where 1=1/0 or 1=1

So as long as the expression is deterministic (truth value can be determined), you can take advantage of short-circuiting.

Though CustomerID = CustomerID seems deterministic in a fleeting glance, it is NOT DETERMINISTIC because in SQL by default null IS NOT EQUAL to null. So the engine cannot determine before hand the value of the left side expression and hence cannot short-circuit and fails.

So the next time you are doing Conditional Where clauses, convert the condition into boolean logic and take advantage of short-circuiting built into SQL Server.

Layman Web 2.0 Video

Micheal Wesch at Kanas State University created this amazing layman Web 2.0 video The Machine is Us/ing Us.



It illustrates the concepts that are shaping today's web in a surprisingly simple way . And to think that he is a cultural anthropology professor amazes me. XML, RSS, Content sharing, Tagging, Social Bookmarking, the idea that the machine is learning a new idea with every click and the creation of a database-backed web are all showcased.

My favorite part is when content from disparate sources seamless blends into the sections of the page where dropped. Drives home the powerful concept of form and content separation.

There is nothing geeky about the video. Must watch for everybody. Repeat after me : We are the Web

Friday, March 30, 2007

Transatlantic with Google Maps

Ever wondered what Google maps would do if your route spanned water bodies. That's what we precisely did today and discovered some amusing things. We entered Cleveland,OH to London,UK and Google Maps did plot us a route across the Atlantic.

And how exactly were we supposed to cross the Atlantic. SWIM ...LOL
And how long was this going to take ... Only 29 days 17 hours.

Afer a hearty laugh, we sat down to dig a little deeper. It seemed to work only from a destination in US to select destinations in Europe across the Atlantic. We tried South America, Europe, Australia, Asia with no luck. Another thing we observed was, a transatlantic "swim" would always take you along the same path in the Atlantic as shown by points 36 and 38, irrespective of the source and destination. Thats how the algorithm seems to work.

This means a traveler from Miami,FL to London,UK will have to go to Newyork, swim across to France and then cross the English Channel. haaa haaa.. God help the guy !

BTW, have your swimsuit ready to plunge into the frigid, shark infested Atlantic waters with Google Maps.

Saturday, March 24, 2007

Life Savers [ Google Bookmarks ]

With millions of sites and gazillions of web pages, it is sometimes hard to land on the perfect page you are looking for. Once you find it, any sane user would be sure to bookmark it(add to favorites).

But the increasing dilemma users like me are facing is how to consolidate everything that has ever been bookmarked. Most of the time I end up emailing myself all the links I have discovered so that they are accessible to me at a later time.

Enter Google Bookmarks... and life is a lot better
Login to your google account and viola all your bookmarks are there . BTW you have to have Google Toolbar installed to access the bookmarks feature, which takes only a couple of minutes to download and install.

You can create labels to organize your bookmarks.It will also allow you to import you exising browser bookmarks. The bookmark organization page allows you to save some comments for each of the links which is kinda cool.

But the last time I checked, It was still missing a lot of good to have features which might be coming in future upgrades of the toolbar. You cannot nest labels right now. Once you add a bookmark, you cannot push it to a different label without actually removing it and re adding it. The online organization page is also rudimentary at best. Given google's fixation for drag drops, may be the page should feature a drag drop interface to reorganize bookmarks.

del.icio.us is another great place to store your bookmarks and extensions are available to use it from the comfort of your toolbar. A lot of other websites have popped up with similar concepts but I believe we still have a long way to go...

Saturday, March 17, 2007

Sand Dunes : Namibia

Nature never ceases to amaze me. Look at these 12000 feet vistas of sand in Namibia. You are sure to gape in awe and wonder at the wonderful artwork of nature.


I first took notice of the mammoth size of these in the Where the hell is Matt? video. Then yesterday a photo of the dunes popped up on BBC photo section.

if using firefox, google map image of Namibia will be displayed
in the div below

la natura, li saluto !

Image Courtesy : Wikipedia and BBC

Friday, March 02, 2007

Life Savers [ BEGIN TRAN ]

Starting with this post, I am planning to do a series titled 'Life Savers' ... tips, tricks, helpers that I learn over the course of my life that are simple, small and yet powerful. I use them day-in and day-out..make my life so much more efficient and managable.

Simple Problem Scenario :
You are to run an UPDATE statement in the Query Analyzer to change the address of a person with AddressID = 1

You try to craft the UPDATE query. Before you do that, it is always a good practice to do an equivalent SELECT statement. So our SELECT query is going to look like this

USE AdventureWorks
GO

SELECT *
FROM Person.Address
WHERE AddressID = 1

(1 row(s) affected)

Now for the UPDATE query

--SELECT *
--FROM Person.Address
UPDATE Person.Address
SET AddressLine1 = '6553 MapleWood Dr '
WHERE AddressID = 1

You run the update and the result window shows
(19614 row(s) affected)

Oops! You were expecting only one row to get updated. To your anguish you realize you forgot to highlight the filter part when you ran the update. Alas ! you are in a big mess now and potentially looking at a long day ahead of you.

Now for our little trick that would have avoided this pitfall.

Before you do any database UPDATE from Query Analyzer, ALWAYS ALWAYS start it with a BEGIN TRAN

BEGIN TRAN

--SELECT *
--FROM Person.Address
UPDATE Person.Address
SET AddressLine1 = '6553 MapleWood Dr '
WHERE AddressID = 1

-- COMMIT TRAN (Or) ROLLBACK TRAN

If the number of rows affected are equivalent to what the SELECT statement gave you, go ahead and do the COMMIT TRAN.

If you see unexpected results like above, do a ROLLBACK TRAN instead.

These 3 simple, amazing lines prevent accidental UPDATEs and can save you tons of time and headache.

Always Recommended.

Update 2007.04.07 : I re-thought about the 'Life Savers' title and in retrospect it seems a little too intense for the topics I am planning to cover under this series. So I will probably be dropping the naming convention in future posts and use something of a milder nature.

Saturday, February 24, 2007

Message Archive

As Life moves forward, memories fade away into oblivion ... and everything you once cherished and held close to your heart are lost forever in the deepest chasms of your brain. You will need the equivalent of bread crumbs to track back and tie the intangible to the tangible to relish those moments once again. And I'm hoping this message archive will make some of that digging easy for me when I am too senile to recall . Lets start with archiving my Orkut profile messages and I intent to archive anything and everything over time. Seems like stupidity right now...but you never know, especially when it involves me!
-----------------------------------------------------------------------
Fiesta Bowl : What a game it was.
Broncos win in OT 43-42 with a gutsy 2 point conversion. College Football cries playoff..playoff..
-----------------------------------------------------------------------
Final Potter book's title is out ..called..'Harry Potter and the Deathly Hallows'
-----------------------------------------------------------------------
.... and we are going to Glendale to play Ohio State ( Go Gators !! )
Sorry Michigan, but you had your shot !!
-----------------------------------------------------------------------
With USC losing, you got to be retarded to leave out the Gators from the Championship Game.
(SEC Championship) Gators top Hogs : 38-28
Gators down Seminoles : 21 -14
Gators rip West Carolina : 62-0
Man this game was soooo close, I was going to cry... Gators escape the "Ol' Ball Coach" : 17-16
Gators survive Vandy : 25-19 ( Headed for the SEC Championship Game )
Gators take care of cocktail party business : 21-14 ( ... and USC goes down )
Error-prone Gators go down at Auburn : [17-27]
LSU Tigers are Gator meat : 23-10
Sweet revenge over the tide : 28-13
20th straight over Kentucky : 26-7
Gators swamp Volunteers with late comeback : 21-20
Gators vs UCF : 42-0
Gators vs Southern Mississippi : 34-7

Wednesday, February 07, 2007

Year Of The Gator

Today was the National Signing Day and the Gators landed another Title - The Nation's Top Recruiting Class.

1 Florida
2 Southern Cal
3 Tennessee
4 LSU
5 Texas
6 South Carolina
7 Auburn
8 Notre Dame
9 Georgia
10 Alabama

There were six SEC teams in the top 10, testament to the toughness and recruiting acumen of the South Eastern Conference.

Come football season and the Gators are going to do another chomp. You can bet on that.

Monday, January 01, 2007

College Football Pick'em

The new year is upon us and so are the BCS bowl games.

As I write, USC dominated the Rose bowl bombarding Michigan 32-18. This should silence all Michigan fans.

No more bickering on how the second best team was denied a chance to play for the national championship and how Florida sneaked in and blah blah blah ...

Imagine the backlash that would have been if Michigan beat USC and Florida lost to the Buckeyes by more than 3 points. Thank God we don't have to see that day.

This year, like every year I played the College Football Pick'em. Though I was intent on being more serious this year, I still missed Week 1. It's fun to do the predictions every week. The point spread makes it tough though.

I did ok this season. Could have been much better. I am planning on doing some betting starting next season. Wish me good luck.

College Football is real fun. Looking forward to the next regular season and of course pick'em.

Phishing Protection

IE7 and Firefox 2.0 have good mechanisms built into them to protect the unwary/casual user from phishing attacks.

Whenever I receive emails from financial establishments, I am extra cautious on what I do with them. I would rather type-in the url than click on some link in my inbox unless it has some state information on the url. In those circumstances, I double check to verify where the link actually takes me.

One of these days I received an email in my yahoo inbox supposedly from Chase. I recognized it right away as a phishing email.

I would generally delete the mail. But with the advertised phishing protection mechanisms of both the browsers, I thought may be I should test to see how these fare.

.. and both of them already had the link in their phishing databases. Responses are below.

FireFox


IE


I submitted the link to Phishtank some days later, but the site had already vanished and was unverifiable.

So guys, always beware. Help yourself by being cautious.

To learn more about the actual implementation, click here for IE and here for Firefox

Friday, October 27, 2006

Browser War : What say you?

With both Firefox 2.0 and IE7 gone gold, the browser war has just become more interesting.

Having used both of them since their early betas, I must admit there is no clear winner. It all depends on how each of them stacks up to your daily needs.

Before I go about putting my personal verdict out there, I must confess I am guilty of one sin : Cherish the underdog status. Thats what lead me to embrace Firefox in its early days. But make no mistake, Firefox is an underdog no more(at least in its feature set). It is in fact IE, that has been trying to catch up with Firefox since 1.5 was out.

This list is by no means a reflection on the complete feature set, its just about WHAT I LIKE....and you guessed it right : Go for Firefox baby !!

- Download manager and a plethora of extensions to customize the look and feel
- Find as you type, Browse with caret, Spell Checking, Session Restore, Live Titles
- Close on each tab without having to view the tab as in IE
- Much more powerful RSS reader than IE ( the bare bones implementation is supposed to be in line with the RSS platform strategy Microsoft is working on )
- As a developer I love View Source editor compared to the crappy notepad
- IE is so tied up to the OS, if something goes wrong, it brings the whole system to its knees
- Far better support for web standards. (IE is the worst out there in this regard)
- Easy patch update cycle to enhance security
- IE required two restarts(had RC build) to install and had a larger EXE. Though it is a one time thing, it turned me off a little bit.

To end, Firefox is not without its share of problems, which i might detail later. In all fairness to IE, i like quite a bit of its features,especially the quick tabs.

The debate as to which is a better browser will go on until something new comes around, but as far as i can see the true winner is really the user.

Saturday, September 09, 2006

Yahoo Sign-In Seal

<< Thoughts on New Technology >>

Yahoo is the first major web portal to push into the realm of Sign-In Seal, a security service to prevent surfers from landing on fake look-alikes of yahoo websites.

The idea is to associate a Yahoo sign-in seal with an individual computer. The seal is chosen by the subscriber, which can be text, color or image of his liking. This seal will be shown each time the user goes to a log-in page for a yahoo service. This helps the user verify if he is on a legitimate yahoo page.

The service has not yet been officially announced and has been rolled out to customers on a random basis.

This is very similar to sign-in seal that Bank Of America and IngDirect already use. But these are associated to the person's id instead of the computer itself.

Impressions:

I like the Bank Of America model better than the yahoo one. Since the seal is associated with a computer, someone else using the machine can change it without your knowledge and deletion of files and cookies affects it as well. In the Bank Of America model, the only fear is of giving away your user Id.

When I tried using the service, I had to associate a Sign-In Seal for each browser I was using. One for IE7, One for FireFox Beta 2 and One for Opera 9. The image did not propagate to all my browsers. I am not sure if this is intended behavior or may be I was missing something.

But this is definitely a huge step forward to prevent surfers from phishing attacks. Lets' see if others like google, hotmail embrace similar technology.

Tuesday, August 22, 2006

Been Six Weeks..huh

<< Ramblings : Keep you healthy >>

been six weeks... long time... huh

I checked my 'Profile Views' today and was astonished to see 73 hits. Not bad for a nobody like me...not at all.

So I decided to knock some rust off, just in-case I have repeat audience, the unwary surfer who accidentally ends up here…again. you know ... I don't want to disappoint them.

Now I wonder what took me so long.
Not that I do not have 'stupid' ideas to fill up pages.
It is that, I do not find time.
hmm...

To Quote Charles Buxton:
'You will never find time for anything. If you want time you must make it.'

So I decided this was the day to assimilate my ideas of 'To Be Blog Entries' and dump them here for later expansion.

So, here goes the list.

Big Fish & its off-beat director Tim Burton
The buffer size problem with vjs*.dll zip functionality
A Beautiful Mind: Ron
Malicious Disobedience
Self-realization
Unexpected behavior of Firefox Beta 1 on SI.com
The Day His World Stood Still
Stupid JavaScript SPAN error and all the laughs we had

funny how time flies by.
Lets see when I will come back to expand on these

till then…Over and Out

Thursday, July 06, 2006

Where the hell is Matt?

Matt Harding, The man who danced his way around the world.

His looney dance, which started as a crazy idea has been watched by millions of people. His destination count : 39 countries and ALL 7 continents.



A second video Where the Hell WAS Matt?
He was also on Good Morning America

On You Tube as some of them commented
'Sometimes the best ideas are the simple ones. Brilliant!'
'It made me feel good as well..I don't really know why..'
'its great how he just left everything to see the world. and that dance will be his trade mark like, FOREVER!'


He reminded everybody that this is a beautiful planet.

Matt, I am your fan !

The Namesake Review

<< Books : Friends For Life >>

gatorIndex: 3.0/5.0
When/Where : On Continental from CLE to PHX

I picked up this book as the next great read from the Pulitzer winner Jumpa Lahiri, expecting an emotional journey down memory lane.

Well I hate to say, the book disappoints a little. Not that it is a bad read or anything. As is said, You are a victim of your own success. Lahiri set high standards for herself with the The Interpreter Of Maladies and this book, I am afraid to say, is not at the same level.

The intensity did not match her previous one and lacked the depth to carry me through the same emotions as the namesake felt.

The author seemingly innocuously bounces off complete years from Gogol's life without warning and on more than one occasion, I had to go back to see if I had unintentionally skipped over some pages or left out some prose.

The curtness with which the author decides to end the four-odd courtships that Gogol has also strikes me as absurd.

A few pages into the novel and you will realize lahiri's fascination with detail. But in a 289 page book that walks us through the life of the namesake, hardly a page ON THE WHOLE is dedicated to the breakups. May be she just wants to do away with the pain and go on with life?

Ruth, from Yale during his undergrad years
Maxine, from his days at Columbia
and Moushumi
all walk out of Gogol's life in less than a page worth of words.

hmm... enough of my analysis, like anybody cares.

Lets wait and see how the movie of the same name directed by Mira Nair comes out like and I believe it will no different.

All in all, the continuity and intensity to sustain my interest was missing in this book.

Sunday, June 18, 2006

Influence:Shawshank Redemption

<< Life Lessons from The Silver Screen >>

As I watched The Shawshank Redemption for the umpteenth time, I realized how much I was in love with the movie and its characters especially Andy Dufresne played by Tim Robbins and Ellis Boyd 'Red' Redding played by Morgan Freeman.

Frank Darabont did a wonderful job adapting the 1982 novella 'Rita Hayworth and Shawshank Redemption' by Stephen King.

Hope, as the movie puts it, is the best of things. Brooks dies because he loses hope, the will to survive,the zeal to get going. Red, though on the same path, is saved by Andy.

Values and integrity is another trait the movie puts forward. Albeit all the scum surrounding him, Andy maintains his values,resists pressure and comes out clean on the other side of the shit pipe. Values are important and you should never forego them, not for a better life, not for a better job.

It was nominated for SEVEN academy awards but won NONE of them.Wondering what hogged all the lime light that year at the academy awards.None other than our own Tom Hanks for Forrest Gump and Quentin Tarantino for Pulp Fiction.

Personal best quotes from the movie

[reading a note left by Andy]
Remember, Red, hope is a good thing. Maybe the best of things. And a good thing never dies.

[after Andy Escapes]
I have to remind myself that some birds aren't meant to be caged. Their feathers are just too bright. And when they fly away, the part of you that knows it was a sin to lock them up does rejoice. Still, the place you live in is that much more drab and empty that they're gone. I guess I just miss my friend.