postgresql complex types support (with nested types too)