drill-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rahul Challapalli (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (DRILL-366) Casting to BigInt from Varchar produces wrong results
Date Wed, 29 Apr 2015 21:38:09 GMT

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

Rahul Challapalli closed DRILL-366.
-----------------------------------

Verified!

> Casting to BigInt from Varchar produces wrong results
> -----------------------------------------------------
>
>                 Key: DRILL-366
>                 URL: https://issues.apache.org/jira/browse/DRILL-366
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Functions - Drill
>            Reporter: Mehant Baid
>            Assignee: Mehant Baid
>            Priority: Blocker
>             Fix For: 0.4.0
>
>         Attachments: DRILL-366.patch
>
>
> Can be reproduced using the following plan:
> {
>     head:{
>         type:"APACHE_DRILL_PHYSICAL",
>         version:"1",
>         generator:{
>             type:"manual"
>         }
>     },
>         graph:[
>         {
>             @id:1,
>             pop:"json-scan",
>             entries: [
>                 {
>                     path : "/tmp/scan4.json"
>                 }
>             ],
>             storageengine: {
>                 "type": "json",
>                 "dfsName": "file:///"
>             }
>         },
>         {
>             pop:"project",
>             @id:2,
>             child: 1,
>             exprs: [ {
>               ref: "int",
>               expr: "cast(integer as bigint)"     
>             } ]
>         },
>         {
>             @id: 3,
>             child: 2,
>             pop: "screen"
>         }   
>     ]         
> } 
> Input file, "/tmp/scan4.json":
> {
>   "integer" : "2008"
> }
> {
>   "integer" : "2007"
> }
> {
>   "integer" : "2006"
> }
> Output:
> 2008
> 2008
> 2008
> From the above output we notice that it always generates values corresponding to the
first row. Looks like the buffer is not getting reset to the next row.



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

Mime
View raw message