Details
-
New Feature
-
Status: Patch Available
-
Major
-
Resolution: Unresolved
-
0.12.0
-
None
-
None
Description
Avro doesn't have native timestamp or date data types. Some tools (e.g. apache Sqoop) work around this by adding the java.sql.Types type number as an "sqlType" attribute to the Avro schema JSON field element. The attached patch makes the Avro SerDe look for an sqlType attribute, and if it is a Hive primitive type that's not an Avro primitive type (i.e. timestamp and date) it returns the appropriate Hive type (the one corresponding to the SQL type).