Re: FROM INSERT after ADD COLUMN

2012-12-09 Thread Bertrand Dechoux
I will reopen the subject a bit. I don't know the details of the RCFile implementation in Hive but if the data were stored that way it is theoretically possible to add the column data even without append and without rewriting the whole file. Does someone has more information on that matter? Regar

Re: Running commands at hive cli or hive thirft startup

2012-12-09 Thread विनोद सिंह
Put a .hiverc file in your home directory containing commands, Hive CLI will execute all of them at startup. Thanks, Vinod On Sun, Dec 9, 2012 at 10:25 PM, John Omernik wrote: > I am looking for ways to streamline some of my analytics. One thing I > notice is that when I use hive cli, or connec

Re: FROM INSERT after ADD COLUMN

2012-12-09 Thread yaboulna
Hello Shreepadma, That's definitely very helpful. I doubted that this would be the case, but I was thinking that maybe there's a way to do it using a merge task. I will change my data structure to make it a bit like HBase, and I hope Hive would still be the right choice for me.. it can be b

RE: FROM INSERT after ADD COLUMN

2012-12-09 Thread Connell, Chuck
I don't think you can do this. Populating new columns is the same as "row level updates" which Hive does not do. AFAIK, your only option is to write a new table, by reading the old table, selecting all of it, appending new values to each row, then writing the longer rows to a new table. Chuck

Re: FROM INSERT after ADD COLUMN

2012-12-09 Thread Shreepadma Venugopalan
Hi Younos, Since HiveQL doesn't support an insert..value statement, you can't insert values into a specific column. Let's assume your table had the following structure before the alter table..add columns statement was executed, tab (a string, b bigint, c double) Furthermore, let's assume that it

FROM INSERT after ADD COLUMN

2012-12-09 Thread yaboulna
Hello, I couldn't find any example of how to populate columns that were added to a table. How would Hive tell which row to append by each value of the newly added columns? Does it do a column name matching? Sincerely, Younos

Re: Drop an HBase backed table

2012-12-09 Thread kulkarni.swar...@gmail.com
Hi David, DROP TABLE is the right command to drop a table. You can look at the hive logs under "/tmp//hive.log" to see why your shell is hanging. With dropping an EXTERNAL TABLE, you are guaranteed that the underlying hbase table won't be touched. On Sun, Dec 9, 2012 at 6:06 PM, David Koch wro

Drop an HBase backed table

2012-12-09 Thread David Koch
Hello, How can I drop a Hive table which was created using "CREATE EXTERNAL TABLE..."? I tried "DROP TABLE ;" but the shell hangs. The underlying HBase table should not be deleted. I am using Hive 0.9 Thank you, /David

Re: Mapping existing HBase table with many columns to Hive.

2012-12-09 Thread David Koch
Hello, I tried the shell command which Swarnim kindly provided and it allows me to map an existing HBase table into Hive. However, since my qualifiers are long but map only accepts string as a key, the result is garbled. Even with the suggested patch which allows binary keys, the resulting datatyp

Re: hive-site.xml not found on classpath

2012-12-09 Thread Stephen Boesch
I ended up patching the HiveConf.java . If hive-site.xml were not found on the classpath then: - an o.a.h.fs.Path object is created from System.getenv("HIVE_CONF_DIR") + File.seperator + "hive-site.xml" - the Path is sent to the base class Configuration.addResource - whiich btw ac

Running commands at hive cli or hive thirft startup

2012-12-09 Thread John Omernik
I am looking for ways to streamline some of my analytics. One thing I notice is that when I use hive cli, or connect to my hive thrift server, there are a some commands I always end up running for my session. If I have multiple CLIs or connections to Thrift, then I have to run it each time. If I l

Re: hive-site.xml not found on classpath

2012-12-09 Thread Stephen Boesch
The first element of the classpath is the right one already.. but I STILL get the hive-site.xml is not found in classpath. Only hive gives me issues. hdfs, mapred, hbase are all running fine. HADOOP_CLASSPATH=:*/shared/hive/conf:* /shared/hive/lib/antlr-runtime-3.0.1.jar:/shared/hive/lib/commons