You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Albert Zhong (Created) (JIRA)" <ji...@apache.org> on 2012/03/21 14:11:39 UTC

[jira] [Created] (HIVE-2887) Var Substitution not working when connecting to a remote hive

Var Substitution not working when connecting to a remote hive
-------------------------------------------------------------

                 Key: HIVE-2887
                 URL: https://issues.apache.org/jira/browse/HIVE-2887
             Project: Hive
          Issue Type: Bug
          Components: CLI
    Affects Versions: 0.8.1
         Environment: Ubuntu 10.10
            Reporter: Albert Zhong


When we use '-h' option to connect to a remove hive, var substitution will not work. 
More exactly, it seemed that the variables passed in the command line do not correctly set to hive cli's configuration variables.

For example, we run hive without -h option, it works fine:
{code}
$ hive -S -d K=123
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
{code} 

But when we run hive with -h option, it doesn't work:
{code}
$ hive -S -d K=123 -h localhost
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
io.bytes.per.checksum=512
...
hive> SET hivevar:B=123;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
{code} 

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HIVE-2887) Var Substitution not working when connecting to a remote hive

Posted by "Albert Zhong (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HIVE-2887?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Albert Zhong updated HIVE-2887:
-------------------------------

    Description: 
When we use '-h' option to connect to a remove hive, var substitution will not work. 
More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.

For example, we run hive without -h option, it works fine:
{code}
$ hive -S -d K=123
hive> SELECT * FROM foo;
123 abc
456 def
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
{code} 

But when we run hive with -h option, it doesn't work:
{code}
$ hive -S -d K=123 -h localhost
hive> SELECT * FROM foo;
123 abc
456 def
hive> SELECT * FROM foo WHERE r1="${K}";
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
io.bytes.per.checksum=512
...
hive> SET hivevar:K=123;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc
{code} 
The same will happen if you use --hivevar to pass variables.

  was:
When we use '-h' option to connect to a remove hive, var substitution will not work. 
More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.

For example, we run hive without -h option, it works fine:
{code}
$ hive -S -d K=123
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
{code} 

But when we run hive with -h option, it doesn't work:
{code}
$ hive -S -d K=123 -h localhost
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
io.bytes.per.checksum=512
...
hive> SET hivevar:B=123;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
{code} 
The same will happen if you use --hivevar to pass variables.

    
> Var Substitution not working when connecting to a remote hive
> -------------------------------------------------------------
>
>                 Key: HIVE-2887
>                 URL: https://issues.apache.org/jira/browse/HIVE-2887
>             Project: Hive
>          Issue Type: Bug
>          Components: CLI
>    Affects Versions: 0.8.1
>         Environment: Ubuntu 10.10
>            Reporter: Albert Zhong
>
> When we use '-h' option to connect to a remove hive, var substitution will not work. 
> More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.
> For example, we run hive without -h option, it works fine:
> {code}
> $ hive -S -d K=123
> hive> SELECT * FROM foo;
> 123 abc
> 456 def
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> {code} 
> But when we run hive with -h option, it doesn't work:
> {code}
> $ hive -S -d K=123 -h localhost
> hive> SELECT * FROM foo;
> 123 abc
> 456 def
> hive> SELECT * FROM foo WHERE r1="${K}";
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> io.bytes.per.checksum=512
> ...
> hive> SET hivevar:K=123;
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc
> {code} 
> The same will happen if you use --hivevar to pass variables.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HIVE-2887) Var Substitution not working when connecting to a remote hive

Posted by "Carl Steinbach (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HIVE-2887?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Carl Steinbach updated HIVE-2887:
---------------------------------

    Component/s: Server Infrastructure
    
> Var Substitution not working when connecting to a remote hive
> -------------------------------------------------------------
>
>                 Key: HIVE-2887
>                 URL: https://issues.apache.org/jira/browse/HIVE-2887
>             Project: Hive
>          Issue Type: Bug
>          Components: CLI, Server Infrastructure
>    Affects Versions: 0.8.1
>         Environment: Ubuntu 10.10
>            Reporter: Albert Zhong
>
> When we use '-h' option to connect to a remove hive, var substitution will not work. 
> More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.
> For example, we run hive without -h option, it works fine:
> {code}
> $ hive -S -d K=123
> hive> SELECT * FROM foo;
> 123 abc
> 456 def
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> {code} 
> But when we run hive with -h option, it doesn't work:
> {code}
> $ hive -S -d K=123 -h localhost
> hive> SELECT * FROM foo;
> 123 abc
> 456 def
> hive> SELECT * FROM foo WHERE r1="${K}";
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> io.bytes.per.checksum=512
> ...
> hive> SET hivevar:K=123;
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc
> {code} 
> The same will happen if you use --hivevar to pass variables.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HIVE-2887) Var Substitution not working when connecting to a remote hive

Posted by "Albert Zhong (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HIVE-2887?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Albert Zhong updated HIVE-2887:
-------------------------------

    Description: 
When we use '-h' option to connect to a remove hive, var substitution will not work. 
More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.

For example, we run hive without -h option, it works fine:
{code}
$ hive -S -d K=123
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
{code} 

But when we run hive with -h option, it doesn't work:
{code}
$ hive -S -d K=123 -h localhost
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
io.bytes.per.checksum=512
...
hive> SET hivevar:B=123;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
{code} 
The same will happen if you use --hivevar to pass variables.

  was:
When we use '-h' option to connect to a remove hive, var substitution will not work. 
More exactly, it seemed that the variables passed in the command line do not correctly set to hive cli's configuration variables.

For example, we run hive without -h option, it works fine:
{code}
$ hive -S -d K=123
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
{code} 

But when we run hive with -h option, it doesn't work:
{code}
$ hive -S -d K=123 -h localhost
hive> SELECT * FROM foo;
123 abc;
456 def;
hive> SELECT * FROM foo WHERE r1="${K}";
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
io.bytes.per.checksum=512
...
hive> SET hivevar:B=123;
hive> SET -v;
...
hive.zookeeper.session.timeout=600000
hivevar:K=123
io.bytes.per.checksum=512
...
hive> SELECT * FROM foo WHERE r1="${K}";
123 abc;
{code} 

    
> Var Substitution not working when connecting to a remote hive
> -------------------------------------------------------------
>
>                 Key: HIVE-2887
>                 URL: https://issues.apache.org/jira/browse/HIVE-2887
>             Project: Hive
>          Issue Type: Bug
>          Components: CLI
>    Affects Versions: 0.8.1
>         Environment: Ubuntu 10.10
>            Reporter: Albert Zhong
>
> When we use '-h' option to connect to a remove hive, var substitution will not work. 
> More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.
> For example, we run hive without -h option, it works fine:
> {code}
> $ hive -S -d K=123
> hive> SELECT * FROM foo;
> 123 abc;
> 456 def;
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc;
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> {code} 
> But when we run hive with -h option, it doesn't work:
> {code}
> $ hive -S -d K=123 -h localhost
> hive> SELECT * FROM foo;
> 123 abc;
> 456 def;
> hive> SELECT * FROM foo WHERE r1="${K}";
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> io.bytes.per.checksum=512
> ...
> hive> SET hivevar:B=123;
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc;
> {code} 
> The same will happen if you use --hivevar to pass variables.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HIVE-2887) Var Substitution not working when connecting to a remote hive

Posted by "Edward Capriolo (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HIVE-2887?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13236107#comment-13236107 ] 

Edward Capriolo commented on HIVE-2887:
---------------------------------------

-d and -hivevar are evaluated by the CLI. --hiveconf as well. To make this happen I think we will pyhsically need to convert these to 'set' commands. So they process on the thrift side.
                
> Var Substitution not working when connecting to a remote hive
> -------------------------------------------------------------
>
>                 Key: HIVE-2887
>                 URL: https://issues.apache.org/jira/browse/HIVE-2887
>             Project: Hive
>          Issue Type: Bug
>          Components: CLI, Server Infrastructure
>    Affects Versions: 0.8.1
>         Environment: Ubuntu 10.10
>            Reporter: Albert Zhong
>
> When we use '-h' option to connect to a remove hive, var substitution will not work. 
> More exactly, it seemed that the variables passed in the command line with -d/--define and/or --hivevar do not correctly set to hive cli's configuration variables.
> For example, we run hive without -h option, it works fine:
> {code}
> $ hive -S -d K=123
> hive> SELECT * FROM foo;
> 123 abc
> 456 def
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> {code} 
> But when we run hive with -h option, it doesn't work:
> {code}
> $ hive -S -d K=123 -h localhost
> hive> SELECT * FROM foo;
> 123 abc
> 456 def
> hive> SELECT * FROM foo WHERE r1="${K}";
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> io.bytes.per.checksum=512
> ...
> hive> SET hivevar:K=123;
> hive> SET -v;
> ...
> hive.zookeeper.session.timeout=600000
> hivevar:K=123
> io.bytes.per.checksum=512
> ...
> hive> SELECT * FROM foo WHERE r1="${K}";
> 123 abc
> {code} 
> The same will happen if you use --hivevar to pass variables.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira