Prevent NPE as reported in https://github.com/eXist-db/exist/issues/254
Smaller code improvements
Merge pull request #261 from dizzzz/community_support

Improve SQL extension