[ https://issues.apache.org/jira/browse/HIVE-5162?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13800220#comment-13800220 ]
Anandha L Ranganathan commented on HIVE-5162: --------------------------------------------- It seems we already have pmod function available. select 44.22 %22,44.22%22.22,pmod(44.22,22),pmod(44.22,22.22) from dual limit 2; OK 0.21999999999999886 22.0 0.21999999999999886 22.0 0.21999999999999886 22.0 0.21999999999999886 22.0 Time taken: 20.954 seconds This will solve your requirement. Please let me know if we can close this ticket. > Add mod(a, b) semantic for modular function > ------------------------------------------- > > Key: HIVE-5162 > URL: https://issues.apache.org/jira/browse/HIVE-5162 > Project: Hive > Issue Type: Improvement > Components: UDF > Affects Versions: 0.11.0 > Reporter: Xiu > Assignee: Anandha L Ranganathan > Priority: Minor > > Currently Hive is supporting 'a % b' as modular function, not mod(a, b). > Unlike MySQL which supports both. > It would be a good idea to support both. -- This message was sent by Atlassian JIRA (v6.1#6144)