In JDBC, all numberings start at one. This is terribly unfortunate design decision, but at least it is consistent across the whole JDBC API. It therefore applies to ResultSetMetaData.getColumnName() too; you're trying to access column at index 0, which does not exist.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com