Database Reference
In-Depth Information
Using Weka with Greenplum
As saw seen in Chapter 3 , Advanced Analytics - Paradigms, Tools, and Techniques ,
Weka is a Java-based analytics framework and an alternative to R. As it is a Java-
based analytics API, it can connect to any database that supports or has a JDBC
driver. Weka comes with a support to a wide range of database and in order to
connect to Greenplum, we would need to use the Data-
baseUtils.props.postgresql properties file and should be extracted to the
HOME directory.
To connect to Postgres/Greenplum from Weka, configure the following properties in
the DatabaseUtils.props.postgresql properties file:
jdbcDriver = org.postgresql.Driver
jdbcURL= jdbc:postgresql://<<domain>>:<<port>>/
Weka has an API InstanceQuery that can be used in the following way to invoke a
Postgres function or stored procedure from the command line:
java InstanceQuery -Q "SELECT * FROM
stored_procedure_name()" -U <user> -P <password>
Search WWH ::

Custom Search