pureXML in DB2

pureXML is the native XML storage capability in IBM DB2. It allows for whole XML documents to be stored in a DB2 table column, and for them to be easily queried via either SQL or XQuery or some combination of the two.DB2 pureXML book Getting Started with DB2 has a decent introduction to both . There’s also schema validation, versioning, and other esoteric features.

I’ve played with it a fair bit and found it quite performant in my admittedly limited scenario of a couple thousand xml docs.

Conor O’Mahony blogs extensively on the topic. In terms of community, there’s an official site, a comprehensive wiki, a forum.

Community

Battle of Gaugamela

October 1st is not just the anniversary of Alexander the Great’s triumph at Gaugamela. It’s not just the birthday of Jimmy Carter. It’s not just the National Day of the PRC.

It’s also the online community action day. It is the day when we comment, we respond, we link, and we blog. It is the day when we go on a forum, like the DB2 Express forum, and answer just one question. It is the day when we pass on the urls of good sites, perhaps PlanetDB2 or ChannelDB2, to our friends and colleagues. It is the day when we find the blog posts that helped us solve an intractable question and say “Thanks! Gracias! Paldies! Spasibo!”

Back

A month ago, Lisa and I returned from Germany. Along with Poland, Latvia, and Estonia, it was the site of our honeymoon. Germany was, of course, beautiful, but I was fascinated to see Latvia again. I hadn’t been back since I had left with my parents in 1995, and it has changed innumerably for the better.

Lisa and Leo Berlin Haupstbahnhof Old Warsaw at Night Riga Meat Market

But I digress. Not only have I learned to say “danke schön”, but so has the free DB2 book. Getting Started with DB2 Express-C is now available in Deutsch.

Getting Started with IBM DB2

I find that it is a good introduction to DB2 Express-C. The latter is the free database server in connection with which I am employed, but whose opinions I do not necessarily represent.

Write to be read

In 1997, Jakob Nielsen wrote How Users Read on the Web. His organization conducted a formal study of usability and found:

  • Concise text (half the words) is 58% more readable than rambling text.
  • Scannable text (bullets) is 47% more readable than wall of text.
  • Neutral language (facts) is 27% more readable than marketese.

Nielsen added specific recommendations:

  • Mark keywords
  • Use descriptive headings (not puns or references)
  • Use bullets
  • Limit one paragraph to one idea
  • Start with the conclusion
  • Halve the wordcount

Concise text

Blaise Pascal: I have only made this letter long because I have not had the time to make it short.

Maintaining high information density is hard. You need to edit and cut the dead text. It takes up your time, but it saves readers time; it is respectful.

Scannable text

I think that Jakob Nielsen and Jeff Atwood overuse bolding. Nevertheless, they remain widely read because their postings are clear and readable. I can see at a glance their topics, their reasoning, and their conclusions.

Neutral Language

Being positive and writing empty boasts is different. Don’t blather about awesomeness, or people will ignore even the facts.

Inverted pyramid style

Observe:

  • Newspaper stories start with the most important fact and work down.
  • Essays start with the thesis and then prove it.
  • Reports start with an executive summary.

ERROR: Failed to build gem native extension.

I ran into a tiny pickle while installing the ibm_db gem on Ubuntu:

Select which gem to install for your platform (i486-linux)
 1. ibm_db 0.9.5 (ruby)
 2. ibm_db 0.9.5 (mswin32)
 3. ibm_db 0.9.4 (ruby)
 4. ibm_db 0.9.4 (mswin32)
 5. Skip this gem
 6. Cancel installation
> 1
Building native extensions.  This could take a while...
ERROR:  While executing gem ... (Gem::Installer::ExtensionBuildError)
    ERROR: Failed to build gem native extension.

ruby extconf.rb install ibm_db
extconf.rb:9:in `require': no such file to load -- mkmf (LoadError)
	from extconf.rb:9

The problem is that mkmf isn’t included in the base Ruby package on Ubuntu. You need need the full development package to install gems from source. Installing it solves the problem.

sudo apt-get install ruby1.8-dev

History meme

Substantial content is in the pipes, but in the meantime here’s Arve Bersvendsen’s history meme:

history | awk '{a[$2]++ } END{for(i in a){print a[i] " " i}}'|sort -rn|head

In my cygwin:

52 python
44 ssh
33 exit
33 cd
18 ls
7 java
5 diff
4 nano
2 ping
1 svn

And on a Linux machine I administrate:

211 sudo
92 ls
80 cd
34 locate
14 nano
6 rm
6 exit
6 cp
3 tar
3 python2.4

I can survive in vi if pressed, but nano is my text-mode editor of choice. I do serious Linux development in Eclipse, Kate, or Kdevelop.

Unknown root password in SuSE Linux

After I installed Suse Linux Enterprise Desktop 10, I tried to update it. It prompted me for a root password even though the install hadn’t asked for one — it had only created a regular user. Sudo didn’t help.

I tried booting in single-user mode, but that also prompted me for the root password.

Finally, I appended init=/bin/bash to the Linux boot command in GRUB. That booted me in a passwordless command line, letting me run passwd and fix things.