0
    =# SELECT code, total_emp FROM sample_07 ORDER BY code LIMIT 3;
    **ERROR:  java.lang.ClassNotFoundException: org.apache.hive.jdbc.HiveDriver**
            at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
            at HadoopJDBCUtils.ConnInitialize(HadoopJDBCUtils.java:74)

    /usr/local/pgsql/lib under this directory i have got the following JARs
    hive-jdbc-2.1.0.2.6.5.8-7-standalone.jar
    hadoop-common-2.8.3-amzn-0.jar
    Hadoop_FDW.jar

我是否需要更改 JAR 文件的任何版本,或者我是否缺少某些东西,创建了扩展 hadoop_fdw

外国数据包装器开发者指南 hadoop_fdw 包装器链接参考

4

1 回答 1

0

在我的情况下也需要重新启动数据库,并设置类路径

 echo $HADOOP_FDW_CLASSPATH
 /usr/local/pgsql/lib/Hadoop_FDW.jar:/usr/local/pgsql/lib/hive-jdbc-2.1.0.2.6.5.8-7- 
 standalone.jar:/usr/local/pgsql/lib/:/home/ec2-user/agensgraph/contrib/hadoop_fdw/
于 2018-08-09T07:30:58.107 回答