code to plot the content of the db

missing: command-line options.
The rest is apparently ok.