public class SQLManager
extends java.lang.Object
Constructor and Description |
---|
SQLManager() |
Modifier and Type | Method and Description |
---|---|
static java.sql.Connection |
getConnectionSafe(java.lang.String url,
java.lang.String username,
java.lang.String password)
Makes sure the appropriate database driver is initialized before calling DriverManager#getConnection.
|
static Job<Frame> |
importSqlTable(java.lang.String connection_url,
java.lang.String table,
java.lang.String select_query,
java.lang.String username,
java.lang.String password,
java.lang.String columns,
java.lang.Boolean useTempTable,
java.lang.String tempTableName,
SqlFetchMode fetchMode,
java.lang.Integer numChunksHint) |
public static Job<Frame> importSqlTable(java.lang.String connection_url, java.lang.String table, java.lang.String select_query, java.lang.String username, java.lang.String password, java.lang.String columns, java.lang.Boolean useTempTable, java.lang.String tempTableName, SqlFetchMode fetchMode, java.lang.Integer numChunksHint)
connection_url
- (Input)table
- (Input)select_query
- (Input)username
- (Input)password
- (Input)columns
- (Input)fetchMode
- (Input)numChunksHint
- (optional) Specifies the desired number of chunks for the target Framepublic static java.sql.Connection getConnectionSafe(java.lang.String url, java.lang.String username, java.lang.String password) throws java.sql.SQLException
url
- JDBC connection stringusername
- usernamepassword
- passwordjava.sql.SQLException
- if a database access error occurs or the url is