[ https://issues.apache.org/jira/browse/SPARK-30004?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16980941#comment-16980941 ]
Takeshi Yamamuro commented on SPARK-30004: ------------------------------------------ I reset the target version; you don't need to set it cuz that will be filled when resolved. > Allow UserDefinedType to be merged into a standard DateType > ----------------------------------------------------------- > > Key: SPARK-30004 > URL: https://issues.apache.org/jira/browse/SPARK-30004 > Project: Spark > Issue Type: Improvement > Components: SQL > Affects Versions: 2.4.4 > Reporter: Fokko Driesprong > Priority: Major > > I've registered a custom type, namely XMLGregorianCalendar which is being > used by Scalaxb. A XML databinding tool, for generating case classes based on > a XSD. I want to convert the XMLGregorianCalendar to a regular TimestampType. > This works, but when I update the table (using Delta), I get an error: > Failed to merge fields 'START_DATE_MAINTENANCE_FLPL' and > 'START_DATE_MAINTENANCE_FLPL'. > Failed to merge incompatible data types TimestampType and > org.apache.spark.sql.types.CustomXMLGregorianCalendarType@5ff12345;; > There are two ways of fixing this: > * Adding a rule which compares the sqlType. > * Change the compare function, so it will check the rhs to the lhs, so I can > override the equals function on the UserDefinedType -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org For additional commands, e-mail: issues-h...@spark.apache.org