Package org.apache.hadoop.hive.conf

Examples of org.apache.hadoop.hive.conf.HiveConf.addResource()


  public CliTableManager() throws Exception {
    HiveConf conf=new HiveConf();
    File f=new File(ConfUtil.getHiveConfDir()+File.separator+"hive-site.xml");
    if(f.exists()){
      conf.addResource(f.toURI().toURL());
    }
    client=new HiveMetaStoreClient(conf);
  }

  public CliTableManager(Configuration conf) throws Exception {
View Full Code Here


     * @return list of columns in comma seperated way
     * @throws Exception if any error occurs
     */
    private List<String> getTableData(String table, String database) throws Exception {
        HiveConf conf = new HiveConf();
        conf.addResource("hive-site.xml");
        ArrayList<String> results = new ArrayList<String>();
        ArrayList<String> temp = new ArrayList<String>();
        Hive hive = Hive.get(conf);
        org.apache.hadoop.hive.ql.metadata.Table tbl = hive.getTable(database, table);
        FetchWork work;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.