[ 
https://issues.apache.org/jira/browse/PHOENIX-1517?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14243481#comment-14243481
 ] 

James Taylor commented on PHOENIX-1517:
---------------------------------------

Yes, the type coercian checks would check that two types are compatible. The 
isSizeCompatible should check that the sizes are compatible - it likely assumes 
the types are already comparable. For example CHAR(10) isn't compatible with 
CHAR(5), but the reverse should be ok. In the same way, a DECIMAL(10,2) isn't 
compatible with a DECIMAL(5,1).

These APIs aren't set in stone, though. The only contract Phoenix has is JDBC 
and SQL from a user perspective.

> PArrayDataType#isSizeCompatible not invoked for all array types
> ---------------------------------------------------------------
>
>                 Key: PHOENIX-1517
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-1517
>             Project: Phoenix
>          Issue Type: Bug
>    Affects Versions: 5.0.0
>            Reporter: Nick Dimiduk
>            Assignee: Nick Dimiduk
>
> I noticed this while debugging failures in ArrayIT with my patch on 
> PHOENIX-1514. It looks like The intention is for all array types to defer 
> their implementation of isSizeCompatible to the implementation in 
> PArrayDataType. However, this is only done for VARCHAR_ARRAY, 
> VARBINARY_ARRAY, BINARY_ARRAY, CHAR_ARRAY, and DECIMAL_ARRAY. Everything 
> else, (basically, all the arrays of primitive types) are invoking the default 
> implementation in PDataType, which always returns true.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to