cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Stupp (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (CASSANDRA-7674) Add implicit casting of UDF arguments
Date Mon, 11 Aug 2014 09:24:13 GMT

     [ https://issues.apache.org/jira/browse/CASSANDRA-7674?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Robert Stupp resolved CASSANDRA-7674.
-------------------------------------

    Resolution: Not a Problem

bq. imo, we shouldn't do automagical stuff

Although I think that upcasting {{int}} to {{bigint}} is a nice feature, some other casts
should definetely avoided (e.g. {{long}} to {{double}}). So this "implicit casting" could
introduce more hidden problems with user code than solve something. We can rely on that {{varint}}/{{decimal}}
sub-typing.

> Add implicit casting of UDF arguments
> -------------------------------------
>
>                 Key: CASSANDRA-7674
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-7674
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Robert Stupp
>
> Writing implementations for each possible combination of even most "primitive" CQL types
is waste of time and results in unclear code.
> E.g. a {{divide}} function should accept {{int, bigint, float, double}} for the first
and second paramter.
> Better if UDF implementation can automagically do some up-casting ({{int}} to {{bigint}},
{{float}} to {{double}} etc).



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message