Improved tree and JDBC samples