Wednesday, November 26, 2008

Memories and sadness from Mumbai terrorist attack

My wife and I lived at an ashram outside of Mumbai for 14 months from 1999-2000. We would go down to Mumbai once a month to see our doctor - Linda was pregnant with Ariel. To make it an easier trip, we'd spend the night and hang out in Mumbai before heading back up to the ashram.

The names of the places - the Taj, the Oberoi, the Indigo Deli, Colaba - all places we have been to and enjoyed. The pictures bring back memories, at a difficult and sad time.

My prayers go out to all those in Mumbai and around India undergoing this horror - we are with you in spirit

Tuesday, November 25, 2008

You did WHAT

My Pa ruminates on the crazy things that were done in the last generation that were done without a second thought - and wondering what we are doing now that could be like that
Dad! You mean you rode around in uncontrolled travelcars that you had to steer yourselves? Didn’t you crash into things? You could even run into one another and get really hurt, if you weren’t watching and steering every minute! How could you sleep?

Thursday, November 20, 2008

Feedback requested: SQL completion in code editors - is it valuable?

I am hoping I can get some feedback from you all.  I have been excited about the support for completion in the NetBeans PHP editor (and other editors to follow).  The response to my quick little blog about this has been pretty positive.

To refresh, here's an example of what it would look like:


But I have also gotten some feedback from more than one source that this may not actually be as valuable as it may first appear.  The reason is that, and this makes sense, the actual work flow when building SQL for your application is as follows:
  • Open SQL tool and write your query
  • Execute, evaluate results, modify, repeat
  • Copy and paste final SQL into your editor
With this flow in mind, it doesn't seem that important to provide completion and other SQL editing features embedded in your application editor, because you need to test to validate that the SQL is correct.

What are your thoughts?  Can you explain to me why SQL editing features in the code editor is valuable, if generally SQL is composed in a SQL tool/editor?

One thing we've talked about is enabling testing from within the code editor.  But it's not clear what this would look like.  We would need to be able to build up an executable SQL statement from SQL that contains substitution variables and may even be a concatenation of multiple strings.  I suppose it's possible, but it seems complicated and error-prone.

I suppose one simplistic approach is the following flow:
  • In your editor, write a full SQL statement as a string
  • right-click and choose "Test SQL" (or run a hot key) to let you test the SQL string right there in the application editor 
  • refine, retest
  • modify the SQL to use substitution variables
At least with this approach you wouldn't have to cut-and-paste, but I'm not sure it buys you much.

So, what are your thoughts?  Your feedback much appreciated.

Wednesday, November 19, 2008

NetBeans: easily generate INSERT statements from query results

I wanted to call out one database tooling feature in NetBeans 6.5 that I think is pretty cool, and it's a little bit hidden.

If you execute a query and you get results, you can then do a number of interesting things with them.


Things like show what the CREATE TABLE statement would look like, or copy and paste the data you have selected (the paste format is hard-coded right now, but next release we plan to support CSV and XML output).

The one I like the best is that you can generate INSERT statements for the data.


Combine this with generating the CREATE TABLE statement, and it makes it really easy to hand your data set to someone else for testing or collaboration.

NetBeans Database Explorer API

It's probably not well known that NetBeans 6.5 comes with a new API called the Database Explorer API. This API allows you to work with and manage the connections that you see in the NetBeans Database Explorer:


Some of the use cases include:
  • Get a connection from the explorer and using it to automate some kind of database functionality, such as generating code based on a database schema
  • Add drivers or connections to the explorer either through a layer file or programmatically
  • Dragging and dropping a table, view or column onto a UI component and then getting metadata for that element. This is used, for example, to bind a database element to a field in Matisse or the visual web toolkit.
There is lots more, take a look at the overview in the javadoc. Geertjan is working on a tutorial showing how to use this API, here's his first blog entry about it with some example code I wrote up for him. More to come.

In the next release, we are making it possible for you to add nodes to the Database Explorer tree and to add actions to a specific node. This is very nice when you want to integrate a database-specific addon plugin to NetBeans.

We also plan to add a metadata API that will allow you to easily inspect database metadata for a given connection without having to dive into the complexities of the JDBC DatabaseMetadata API.

Python in NetBeans - Early Access

Lots of news today. Looks like we have a pretty cool early access of Python support available.

From the Python page:
  • Python project support
  • Fully featured editor
  • Interactive interpreter console
  • Debugging for Jython and CPython
Take a look at Tor's blog for some very nice screen shots, and go here to get the software. You can check out a tutorial here.

Sun Gives MySQL A Query Analyzer -- InformationWeek

By moving the sorting out of the database and back into the application, plus putting a limit on how many stories would be returned to any first request, Freund watched query execution time drop from an average 5.27 seconds down to 2.54 seconds. In other words, Clickability chopped 48% of the time it took to execute each query out of his overhead. The new tool "gave us a snapshot. We learned more about query usage in two minutes than we could gain in two years of ad hoc log analysis and guessing,"

NetBeans 6.5 now officially released!

Wow, it's so cool when something you've worked and worked on finally sees the light of day and goes GA. There's lots in this release, but one of the area's I'm most excited about is the PHP support. Our editor teams produce awesome stuff, and this is no exception, IMHO.

Of course there is also the cool stuff we've done in the databases area:
  • SQL code completion
  • SQL history
  • Editable, pageable results
  • Export results as SQL INSERT statements
  • Easy installation of Sakila sample database
Go get the bits, have fun.

MySQL Query Analyzer - first impressions

Very interesting review of the new MySQL Query Analyzer that comes with MySQL Enterprise Monitor.
I installed Quan (Query Analyzer) and within about 20 minutes it became clear I had a query that was averaging 14 seconds to run. This query doesn't get run all that often, every 5 minutes or so, but it uses a table that is the most active table on our system.

OK, click on the query and it pops up a full view, showing the query with literals replaced by place holders. If you have Example Queries configured, you can check to see if there is an example showing all of the data, and if you have Example Explain configured, you will also be able to get a full breakdown of what indexes will be used in resolving the query.

With a few minutes of checking the query and fine tuning it I was able to get it down to 0.15 seconds on average. That is almost a 100 fold improvement.

Tuesday, November 18, 2008

Giving up on Feedburner, trying Clicky

Since I changed my Blogger template, Feedburner has been dead, showing me no data. I tried re-registering my blog, no dice. I finally took the time to search the knowledge base, and this is what I saw. Not good.

So, I decided it was time to move on. I checked out Google Analytics, but they're talking to someone who isn't me. It's all about monetization and improving your click throughs blah blah blah.

So I looked around, and now I'm trying out Clicky. So far I'm pretty happy with it. Sad thing about Feedburner... I wish Google would just explicitly kill it instead of letting it quietly die.

SQL completion - in PHP?

Thanks to Andrei (before he moved on to bigger and better things), we now have this in the nightly builds.


Take a look - yes, you're getting column names in the completion list when working with a string literal in PHP. And notice how it works with aliases...

It's a prototype, but it's a good start, and we expect to have something like this working for you in

SFTP support in NetBeans PHP

Great news! NetBeans PHP team just added SFTP support. Note this is in the development build, which you can get here

Friday, November 14, 2008

Screencast: new database features in NetBeans 6.5

Andrei Badea, one of our team members, does an excellent screencast showing off some of the new database features in NetBeans 6.5 (due to release next week). Things like code completion, editable results, multiple result tabs, SQL history and easy creation of the Sakila sample database.

Nice NetBeans PHP screencast

Justin Bolter has a nice screencast on using the NetBeans PHP support to build a Flickr slideshow application. A nice way to get a sense of the PHP features in NetBeans.

Sun lays off 6000 and restructures Software division

I just read the news.

I don't know about you, but I was pretty much expecting this. Even though it may cost me my job, I am glad they bit the bullet and cut 15%. We're just burning too much cash and the size of the company didn't match its current market cap.

How do I feel? Relieved, in a way, because I knew it was coming. Am I affected? I have no idea. Nobody's telling the peeps yet, that will happen in the next few weeks.

Software is getting seriously reorganized. NetBeans is now part of the cloud computing platform. Why? My blog, my opinion: because I think Sun gets it that what Sun can offer in this space is a developer platform. Amazon Web Services is a bunch of cogs and wheels targeted at system admins. Google App Engine is focused on a very small slice of developers who are willing to work with Python and BigTable and don't mind locking themselves in to Google.

But Sun has something more to offer, a different path to take. If you combine the strength of the NetBeans development environment with a cloud platform, now you have something interesting. I look forward to see what this looks like.

The Open Office team is also part of the same group. Now that's intriguing. Open Office has a lot to offer over a pure SAAS play like Google Apps. I can envision (again this is just me thinking, don't think I have any kind of "in" to what's actually going on), I said, I can envision taking parts of Open Office and "cloud-enabling" them, while continuing to give a rich desktop experience. For example, I can envision saving my documents to a cloud-based storage service so I can access them anywhere, or adding collaboration features to OpenOffice ala Google Spreadsheets.

Similar realignments are helping elsewhere in Software. The OpenSolaris group is joining the Systems group so they can focus on innovative integrated solutions like OpenStorage. The MySQL team is going to work with the rest of the application platform folks like Glassfish and Identity to provide a complete solution with add-on and optimized products and services that can bring in revenue.

So there is a lot of opportunity here to innovate and make money (and of course an opportunity to fall flat on our faces :)). The question, as always, is, can we pull it off, will it be enough? Is this the right direction? Well, we'll just have to see. I may be crazy, but I like this company. People here are smart, innovative, dedicated and kind. I'm hopeful. The audacity of hope.

And will I be there to see Sun come out the other end? Well, we'll just have to see... :)

Thursday, November 13, 2008

Michael Lewis - The End of Wall Street's Boom

From the author of Liar's Poker comes an excellent and disturbing article about the culture of Wall Street and how incredibly greedy and free of conscience the folks were who were making a killing using other people's money.

Wednesday, November 12, 2008

Graph of databases used by NetBeans users

You may have seen this already, but this nifty little graph shows what databases our users are using. The biggest one by far is MySQL, followed by JavaDB/Derby and Oracle.

We get this data through collecting "gestures" - where we track the clicks and actions performed by users who "opt in." In this case we detect what database vendors our users connect to through NetBeans.

Net bombarded by heaviest ever attacks this year | Tech News on ZDNet

This is cause for concern. Not only hackers but governments are discovering the impact of a Net attack. Distributed Denial of Service uses computers like yours and mine. So many people connected, so many vulnerabilities, and lots of reason to find them.

Thursday, November 06, 2008

She kissed me just for being an American

VIENNA, Austria — She was a stranger, and she kissed me. Just for being an American.

It happened on the bus on my way to work Wednesday morning, a few hours after compatriots clamoring for change swept Barack Obama to his historic victory. I was on the phone, and the 20-something Austrian woman seated in front of me overheard me speaking English.

Without a word, she turned, pecked me on the cheek and stepped off at the next stop.

Lincoln Memorial during acceptance speech

I found 25 or so people who had made their way in the dark to the marble steps of the memorial and stood silently around a lone transistor radio.

Why the jubilation?

I've been thinking about it: why are so many people so happy (including myself) that Obama won the election?

I think there are a number of reasons.

First, it is just plain amazing that a black man will be our next president. It just never seemed possible, and I still feel like I'm pinching myself. In a profound way, it has healed and old old wound in this country. No limitations.

Secondly, I think many of us weren't consciously aware of the emotional damage being done to us watching those in power lie, cheat and steal in a million offensive and painful ways. Almost every day for eight years we have been hurt and outraged by the immoral acts of our administration. It just places a heavy burden on you.

And then, like that, it's gone. Thus, the jubilee. With the lifting of that burden comes elation, and tears. We did it. We are rid of the scoundrels. I don't think any of us expected the power of that feeling when Obama finally won. It was like a tidal wave of relief, for the whole world. We try to be realistic, be cynical, but the relief just overflows.

Then there is Barack Obama himself. You can never really tell, but all signs point to him being an excellent president, a president who serves his country rather than use the position as a way to party and profit. He inspires, he is thoughtful, he listens, and he comforts with his calm and discipline. His family seems truly happy and loving. They seem to be good people.

My final feeling of joy and hope is that, in no small part due to power of the social web, we seem to now be able to elect someone who has not been anointed by the powers that be. Obama defeated the Clinton machine and the Republican machine. That would not have been possible without the money and volunteering from an army of citizens.

Now I'm sure if McCain had won, he would have been a different president than Bush, and there would have been some relief in that. But he was backed by the same scoundrels who backed Bush, and I believe that if he had won, it would have been like a stamp of approval to business as usual. The rest of us, both in the USA and outside of it, would have crawled back into our holes to hunker down and weather it through.

There are difficult days ahead. There are still major issues with the structure of our system. But at least we were able to make our voices heard, and we are now prepared to team together with our government to work to heal these problems, rather than watch with chagrin, outrage and a sense of powerlessness as our administration and their cronies ransack the country.

Wednesday, November 05, 2008

Proposition 8 - If it wins, what next?

It looks like Proposition 8 is winning.  I heard on the radio that the Prop 8 folks are planning on going to the Supreme Court to argue that all existing gay marriages done by the state be annulled.  Sigh...

My take on this: it's an ongoing effort.  One has to hold the vision of where we want to go.  Barack Obama, a black man, is now our next president.  Yes we can.

This last week, I listened a lot to the concerns of the Yes on 8 folks.  What I am hearing is that they have strong religious beliefs that marriage is between a man and a woman.  There is a sense that any other kind of marriage is "unnatural."   There is a feeling of the sanctity of marriage, that it is a union blessed by God and should not be tampered with by the State.

I can see how one might think that way.  I can see how the thought of a gay couple getting married is like "ewww" and feels "wrong."  One could argue, well, why not allow a man or woman to marry a sheep next?

But seeing so many gay couples get married, these arguments just fall away.  I wish those who feel gay marriage is "wrong" or "unnatural" could be at these weddings like a fly on the wall and see the love that is there. 

When I am at these weddings, I see the sanctity in their vows.  The power of those vows and that commitment is there as fully as at the heterosexual weddings I have been at.  I feel God's blessings and support descend upon these couples during their vows like a blanket of light. 

What is sacred and holy is not the shape of the bodies containing two loving souls, but the love itself, and the act of commitment and sacrifice that makes that love manifest.  The outer form of the two souls is just window dressing.

Since I have had that experience, I believe that it is morally right that we should allow any two loving souls to make the commitment of marriage.  Anything that prevents that is discrimination and goes against God's loving nature.  So, the fight goes on.

Near-Flawless Run Is Credited in Victory - NYTimes

Great article. Money quote:
It was a phenomenon captured in a photograph ... shared last week of a homemade sign with the Confederate flag. It read: “Rednecks for Obama. Even we’ve had enough."

Tuesday, November 04, 2008

Kisumu - A Kenyan Town With Its Eyes on the Election

Ah, I remember Kisumu well. Right there on the side of Lake Victoria. It was the nearest big town from Rusinga Island, where I spent two separate long stints as a child when my parents were doing research (geology and paleontology) for Louis Leakey.

I still remember the Luo tribe, which is the tribe Barack Obama's father comes from. They had beautiful shining black faces with high cheekbones and dazzling smiles. They were always so friendly and loving and open-hearted. Hard to imagine that town bursting into riots.

What a strange connection with my childhood.

Monday, November 03, 2008

NetBeans for PHP : weblog

Petr Pisl describes his experience of turning PHP users on to the PHP support in NetBeans. Great stuff, I could almost see myself there as people start realizing what we have to offer.

Awakening the Balrog

I think the following video is a perfect underscore to Paul Krugman's somewhat disturbing comments on the future of the Republican Party.

By the way, I grew up in Colorado. I've met people like this and gone to school with them. They helped make junior high school miserable. When I first came to Colorado some of the boys told me my parents were hippies. I had never heard what a hippie was, and when I asked them, they said that hippies walked around naked, lived in caves, and peed outside. Even at that age, I wasn't sure what to make of that. Some comments just stop your mind.

It's also disconcerting that the McCain/Palin ticket seems to be drumming up/stirring up these kinds of passionate, fear-and-anger-based feelings. It reminds me of what the dwarfs did in the Mines of Moria - be careful how deep you dig, as you may unleash a power greater and older than anything you can handle. The Balrog is being awakened...

California Proposition 8 - My Viewpoint

I don't normally do this, but this particular initiative really hits home for me. My mother just came to the Bay Area this summer and married her partner of over 20 years. I have had many good friends get married this summer, with tears in their eyes, where for so long they were denied this right. You can tell this means so much to them.

Now, for reasons I don't fully understand, there is strong support to eliminate this right by explicitly disallowing anyone to marry except a man and a woman.

I can understand having strong feelings about who can marry, and even belonging to a church, temple, mosque or other organization that does not condone or support gay marriage.

But why does this mean removing the right for a gay couple to marry within the state of California? To me this is imposing one's own beliefs upon everyone. There are orthodox rabbis who will only marry two Jews. Does this mean we should have an amendment that says that only two people of the same faith can marry?

My heart breaks at the thought that my Mom's marriage, and the marriage of my friends, will be invalidated by the state constitution, and that future couples will be denied the right to marry and enjoy the same rights and responsibilities the rest of us have.

So, if you're in California, please vote NO on Prop 8.

Whether you live in California or not, you can help in other ways, through donations or volunteering, at