[jira] [Commented] (NIFI-2422) SelectHiveQL processor failed to process a 'select' query

2016-07-29 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/NIFI-2422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15399903#comment-15399903
 ] 

ASF GitHub Bot commented on NIFI-2422:
--

Github user asfgit closed the pull request at:

https://github.com/apache/nifi/pull/744


> SelectHiveQL processor failed to process a 'select' query
> -
>
> Key: NIFI-2422
> URL: https://issues.apache.org/jira/browse/NIFI-2422
> Project: Apache NiFi
>  Issue Type: Bug
>Affects Versions: 1.0.0
>Reporter: Matt Burgess
>Assignee: Matt Burgess
> Fix For: 1.0.0
>
>
> The following query configured in SelectHiveQL processor will generate ERRORs 
> shown in the attached screenshot:
> SELECT * FROM hiveql_test_table WHERE nifinode="node1"
> However, I can run the above query successfully if I connect to the hive 
> server directly.
> The hive table schema is as follows:
> 0: jdbc:hive2://localhost:1/hiveql_test_d> desc hiveql_test_table;
> +---+---+--+--+
> | col_name  |   data_type   | comment  |
> +---+---+--+--+
> | id| int   |  |
> | nifinode  | string|  |
> | tvarchar  | varchar(100)  |  |
> | tchar | char(50)  |  |
> | tboolean  | boolean   |  |
> | tint  | int   |  |
> | tfloat| float |  |
> | tdouble   | double|  |
> | tdate | date  |  |
> +---+---+--+--+
> 9 rows selected (0.416 seconds)



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


[jira] [Commented] (NIFI-2422) SelectHiveQL processor failed to process a 'select' query

2016-07-29 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/NIFI-2422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15399902#comment-15399902
 ] 

ASF subversion and git services commented on NIFI-2422:
---

Commit b213ed95e02392093925c3f2195ef2382423f2b1 in nifi's branch 
refs/heads/master from [~mattyb149]
[ https://git-wip-us.apache.org/repos/asf?p=nifi.git;h=b213ed9 ]

NIFI-2422: Fix SelectHiveQL handling of Number types

This closes #744.

Signed-off-by: Bryan Bende 


> SelectHiveQL processor failed to process a 'select' query
> -
>
> Key: NIFI-2422
> URL: https://issues.apache.org/jira/browse/NIFI-2422
> Project: Apache NiFi
>  Issue Type: Bug
>Affects Versions: 1.0.0
>Reporter: Matt Burgess
>Assignee: Matt Burgess
> Fix For: 1.0.0
>
>
> The following query configured in SelectHiveQL processor will generate ERRORs 
> shown in the attached screenshot:
> SELECT * FROM hiveql_test_table WHERE nifinode="node1"
> However, I can run the above query successfully if I connect to the hive 
> server directly.
> The hive table schema is as follows:
> 0: jdbc:hive2://localhost:1/hiveql_test_d> desc hiveql_test_table;
> +---+---+--+--+
> | col_name  |   data_type   | comment  |
> +---+---+--+--+
> | id| int   |  |
> | nifinode  | string|  |
> | tvarchar  | varchar(100)  |  |
> | tchar | char(50)  |  |
> | tboolean  | boolean   |  |
> | tint  | int   |  |
> | tfloat| float |  |
> | tdouble   | double|  |
> | tdate | date  |  |
> +---+---+--+--+
> 9 rows selected (0.416 seconds)



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


[jira] [Commented] (NIFI-2422) SelectHiveQL processor failed to process a 'select' query

2016-07-29 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/NIFI-2422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15399860#comment-15399860
 ] 

ASF GitHub Bot commented on NIFI-2422:
--

Github user bbende commented on the issue:

https://github.com/apache/nifi/pull/744
  
Reviewing...


> SelectHiveQL processor failed to process a 'select' query
> -
>
> Key: NIFI-2422
> URL: https://issues.apache.org/jira/browse/NIFI-2422
> Project: Apache NiFi
>  Issue Type: Bug
>Affects Versions: 1.0.0
>Reporter: Matt Burgess
>Assignee: Matt Burgess
> Fix For: 1.0.0
>
>
> The following query configured in SelectHiveQL processor will generate ERRORs 
> shown in the attached screenshot:
> SELECT * FROM hiveql_test_table WHERE nifinode="node1"
> However, I can run the above query successfully if I connect to the hive 
> server directly.
> The hive table schema is as follows:
> 0: jdbc:hive2://localhost:1/hiveql_test_d> desc hiveql_test_table;
> +---+---+--+--+
> | col_name  |   data_type   | comment  |
> +---+---+--+--+
> | id| int   |  |
> | nifinode  | string|  |
> | tvarchar  | varchar(100)  |  |
> | tchar | char(50)  |  |
> | tboolean  | boolean   |  |
> | tint  | int   |  |
> | tfloat| float |  |
> | tdouble   | double|  |
> | tdate | date  |  |
> +---+---+--+--+
> 9 rows selected (0.416 seconds)



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


[jira] [Commented] (NIFI-2422) SelectHiveQL processor failed to process a 'select' query

2016-07-29 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/NIFI-2422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15399392#comment-15399392
 ] 

ASF GitHub Bot commented on NIFI-2422:
--

GitHub user mattyb149 opened a pull request:

https://github.com/apache/nifi/pull/744

NIFI-2422: Fix SelectHiveQL handling of Number types



You can merge this pull request into a Git repository by running:

$ git pull https://github.com/mattyb149/nifi NIFI-2422

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/nifi/pull/744.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #744


commit 4ca6e3e173d262fbaa2aec360d1330296cf04a49
Author: Matt Burgess 
Date:   2016-07-29T14:07:04Z

NIFI-2422: Fix SelectHiveQL handling of Number types




> SelectHiveQL processor failed to process a 'select' query
> -
>
> Key: NIFI-2422
> URL: https://issues.apache.org/jira/browse/NIFI-2422
> Project: Apache NiFi
>  Issue Type: Bug
>Affects Versions: 1.0.0
>Reporter: Matt Burgess
>Assignee: Matt Burgess
> Fix For: 1.0.0
>
>
> The following query configured in SelectHiveQL processor will generate ERRORs 
> shown in the attached screenshot:
> SELECT * FROM hiveql_test_table WHERE nifinode="node1"
> However, I can run the above query successfully if I connect to the hive 
> server directly.
> The hive table schema is as follows:
> 0: jdbc:hive2://localhost:1/hiveql_test_d> desc hiveql_test_table;
> +---+---+--+--+
> | col_name  |   data_type   | comment  |
> +---+---+--+--+
> | id| int   |  |
> | nifinode  | string|  |
> | tvarchar  | varchar(100)  |  |
> | tchar | char(50)  |  |
> | tboolean  | boolean   |  |
> | tint  | int   |  |
> | tfloat| float |  |
> | tdouble   | double|  |
> | tdate | date  |  |
> +---+---+--+--+
> 9 rows selected (0.416 seconds)



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


[jira] [Commented] (NIFI-2422) SelectHiveQL processor failed to process a 'select' query

2016-07-28 Thread Matt Burgess (JIRA)

[ 
https://issues.apache.org/jira/browse/NIFI-2422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15397885#comment-15397885
 ] 

Matt Burgess commented on NIFI-2422:


According to the following, if a floating-point literal is inserted into a Hive 
Table, it is evaluated as a double:

This means when getObject() is called on the JDBC driver, it returns a Double 
not a Float. However if you get its JDBC type, it returns 6 (FLOAT). This seems 
like a Hive bug, but I couldn't find a Jira. For SelectHiveQL, we can change 
the logic from looking for Number objects in the result set and putting them 
directly into the Avro record, to checking the JDBC type and explicitly calling 
the getXYZ method for that type (getFloat() instead of getObject() if JDBC type 
is 6, e.g.)

> SelectHiveQL processor failed to process a 'select' query
> -
>
> Key: NIFI-2422
> URL: https://issues.apache.org/jira/browse/NIFI-2422
> Project: Apache NiFi
>  Issue Type: Bug
>Affects Versions: 1.0.0
>Reporter: Matt Burgess
>Assignee: Matt Burgess
> Fix For: 1.0.0
>
>
> The following query configured in SelectHiveQL processor will generate ERRORs 
> shown in the attached screenshot:
> SELECT * FROM hiveql_test_table WHERE nifinode="node1"
> However, I can run the above query successfully if I connect to the hive 
> server directly.
> The hive table schema is as follows:
> 0: jdbc:hive2://localhost:1/hiveql_test_d> desc hiveql_test_table;
> +---+---+--+--+
> | col_name  |   data_type   | comment  |
> +---+---+--+--+
> | id| int   |  |
> | nifinode  | string|  |
> | tvarchar  | varchar(100)  |  |
> | tchar | char(50)  |  |
> | tboolean  | boolean   |  |
> | tint  | int   |  |
> | tfloat| float |  |
> | tdouble   | double|  |
> | tdate | date  |  |
> +---+---+--+--+
> 9 rows selected (0.416 seconds)



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