Monthly Archives: September 2012

Stored procedures in HSQLDB

Posted by & filed under Uncategorized.

The only way to implement stored procedures in older versions of HSQLDB involved calling static methods in Java code.  Starting in version 2.2, HSQLDB supports stored-procedures as predefined SQL calls.  Documentation and examples of how to do this are not ideal or abundant.  Here is an example. DROP SCHEMA IF EXISTS example cascade CREATE SCHEMA […]

Cloning, Backing-up or Mirroring a Subversion Repository

Posted by & filed under Uncategorized.

Perhaps you’d like to create a read-only mirror of your svn repository or clone your repository so that you can make some organizational changes but are afraid to do so in the live production server.  Or maybe you just simply want to make a backup of your subversion repository. If you are a subversion admin […]

Pretty Print XML and JAXB Marshalling/Unmarshalling

Posted by & filed under Uncategorized.

I always seem to forget how to print XML with pretty-print enabled.   A quick google search reveals that there are a few third party libaries, XOM and JDom.  If you want to use a method that comes with the JDK using the included apache library, here is how you do it.   public void marshalAndPrettyPrintTest() […]

Scripting FTP

Posted by & filed under Uncategorized.

I recently had to add a step to a shell script that uses FTP to copy a file to a remote server.  Usually I’d use scp, secure copy, but for some reason I had to use FTP.  It had been a while since I had done this and didn’t quite remember how to do it. […]

Incorporating a Javascript/CSS plugin into a Maven build process using the Maven Minify plugin.

Posted by & filed under Uncategorized.

Finally, I was able to get a javascript minify plugin working.  http://maven-samaxes-plugin.googlecode.com/svn-history/r123/sites/maven-minify-plugin/index.html It uses YUI compressor under the hoods.  It combines Javascript into one file, CSS into another file and then uses the YUI compressor to minify the two files.  To preserve comments in the minified file, use /*! sequence at the start of a […]