You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Kunal Khatua (JIRA)" <ji...@apache.org> on 2018/05/25 06:56:00 UTC

[jira] [Commented] (DRILL-1530) Support for the != operator

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

Kunal Khatua commented on DRILL-1530:
-------------------------------------

{{There is already the <> operator that does the same.}}

> Support for the != operator
> ---------------------------
>
>                 Key: DRILL-1530
>                 URL: https://issues.apache.org/jira/browse/DRILL-1530
>             Project: Apache Drill
>          Issue Type: Improvement
>          Components: Execution - Relational Operators
>    Affects Versions: 0.6.0
>            Reporter: Chris Matta
>            Priority: Major
>             Fix For: Future
>
>
> Tableau is using the != (not equal) operator in the bellow query which failed tonight with Drill. This operator isn’t technically ANSI SQL, but almost all DBMS support it, any chance this support would be added?
> {code:sql}
> SELECT CASE 
>            WHEN `twitter_tweets`.`favorite_count` / 1 < 0 
>                 AND `twitter_tweets`.`favorite_count` / 1 != `twitter_tweets`.`favorite_count` / 1 THEN `twitter_tweets`.`favorite_count` / 1 - 1 
>            ELSE `twitter_tweets`.`favorite_count` / 1 
>        END AS `Favorite_Count__bin_`, 
>        COUNT(`twitter_tweets`.`favorite_count`) AS `cnt_favorite_count_ok` 
> FROM `mfs.views`.`twitter_tweets` `twitter_tweets` 
> INNER JOIN `mfs.views`.`twitter_users` `twitter_users` ON (`twitter_tweets`.`user_id` = `twitter_users`.`user_id`) 
> GROUP BY CASE 
>              WHEN `twitter_tweets`.`favorite_count` / 1 < 0 
>                   AND `twitter_tweets`.`favorite_count` / 1 != `twitter_tweets`.`favorite_count` / 1 THEN `twitter_tweets`.`favorite_count` / 1 - 1 
>              ELSE `twitter_tweets`.`favorite_count` / 1 
>          END
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)