You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "kimsia (JIRA)" <ji...@apache.org> on 2016/03/05 15:56:40 UTC

[jira] [Updated] (DRILL-4481) Cannot use NEGATIVE on Float8

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

kimsia updated DRILL-4481:
--------------------------
    Description: 
When I run a query like this

```
SELECT NEGATIVE(`EX QTY`) , `contract_symbol`, `contract_expiration_month` FROM dfs.`/src/Apps/BobBrokerJapanFutures.xlsx.json` WHERE  `B/S` = 'S'
```

the query returns error message saying

Query Failed: An Error Occurred
org.apache.drill.common.exceptions.UserRemoteException: SYSTEM ERROR: SchemaChangeException: Failure while trying to materialize incoming schema. Errors: Error in expression at index -1. Error: Missing function implementation: [negative(FLOAT8-OPTIONAL)]. Full expression: --UNKNOWN EXPRESSION--.. Fragment 0:0 [Error Id: 0d38ceb9-c490-442b-87da-a22043093abd on vagrant-ubuntu-trusty-64:31010

I checked the docs and it didn't say anything about the data type for the function NEGATIVE.

https://drill.apache.org/docs/math-and-trig/

Here's the weird thing. I experimented with ABS instead.

```
SELECT ABS(`EX QTY`) as `quantity`, `contract_symbol`, `contract_expiration_month` FROM dfs.`/src/Apps/BobBrokerJapanFutures.xlsx.json` WHERE  `B/S` = 'S'
```

As you can see exact same query except for the change in function.

Works perfectly.

Please let me know if I did this wrongly or was it an actual bug.

Thank you.

  was:
When I run a query like this

```
SELECT NEGATIVE(`EX QTY`) , `contract_symbol`, `contract_expiration_month` FROM dfs.`/src/Apps/reconwise_demo_files/BobBrokerJapanFutures.xlsx.json` WHERE  `B/S` = 'S'
```

the query returns error message saying

Query Failed: An Error Occurred
org.apache.drill.common.exceptions.UserRemoteException: SYSTEM ERROR: SchemaChangeException: Failure while trying to materialize incoming schema. Errors: Error in expression at index -1. Error: Missing function implementation: [negative(FLOAT8-OPTIONAL)]. Full expression: --UNKNOWN EXPRESSION--.. Fragment 0:0 [Error Id: 0d38ceb9-c490-442b-87da-a22043093abd on vagrant-ubuntu-trusty-64:31010

I checked the docs and it didn't say anything about the data type for the function NEGATIVE.

https://drill.apache.org/docs/math-and-trig/

Here's the weird thing. I experimented with ABS instead.

```
SELECT ABS(`EX QTY`) as `quantity`, `contract_symbol`, `contract_expiration_month` FROM dfs.`/src/Apps/reconwise_demo_files/BobBrokerJapanFutures.xlsx.json` WHERE  `B/S` = 'S'
```

As you can see exact same query except for the change in function.

Works perfectly.

Please let me know if I did this wrongly or was it an actual bug.

Thank you.


> Cannot use NEGATIVE on Float8
> -----------------------------
>
>                 Key: DRILL-4481
>                 URL: https://issues.apache.org/jira/browse/DRILL-4481
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Execution - Data Types, Functions - Drill
>    Affects Versions: 1.5.0
>         Environment: Distributor ID:	Ubuntu
> Description:	Ubuntu 14.04.3 LTS
> Release:	14.04
> Codename:	trusty
> java -version
> java version "1.8.0_60"
> Java(TM) SE Runtime Environment (build 1.8.0_60-b27)
> Java HotSpot(TM) 64-Bit Server VM (build 25.60-b23, mixed mode)
>            Reporter: kimsia
>
> When I run a query like this
> ```
> SELECT NEGATIVE(`EX QTY`) , `contract_symbol`, `contract_expiration_month` FROM dfs.`/src/Apps/BobBrokerJapanFutures.xlsx.json` WHERE  `B/S` = 'S'
> ```
> the query returns error message saying
> Query Failed: An Error Occurred
> org.apache.drill.common.exceptions.UserRemoteException: SYSTEM ERROR: SchemaChangeException: Failure while trying to materialize incoming schema. Errors: Error in expression at index -1. Error: Missing function implementation: [negative(FLOAT8-OPTIONAL)]. Full expression: --UNKNOWN EXPRESSION--.. Fragment 0:0 [Error Id: 0d38ceb9-c490-442b-87da-a22043093abd on vagrant-ubuntu-trusty-64:31010
> I checked the docs and it didn't say anything about the data type for the function NEGATIVE.
> https://drill.apache.org/docs/math-and-trig/
> Here's the weird thing. I experimented with ABS instead.
> ```
> SELECT ABS(`EX QTY`) as `quantity`, `contract_symbol`, `contract_expiration_month` FROM dfs.`/src/Apps/BobBrokerJapanFutures.xlsx.json` WHERE  `B/S` = 'S'
> ```
> As you can see exact same query except for the change in function.
> Works perfectly.
> Please let me know if I did this wrongly or was it an actual bug.
> Thank you.



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