Fix and add unit tests for Hive nested types

Trying to read maps with Hive would break. This pull request fixes it.