public class CiscoLMSDatabaseAccessObject
extends java.lang.Object
| Constructor and Description |
|---|
CiscoLMSDatabaseAccessObject(java.lang.String host,
java.lang.String port,
java.lang.String dbName,
java.lang.String userName,
java.lang.String password,
java.lang.String databaseType,
java.lang.String connString)
Constructor for the DB access object
|
| Modifier and Type | Method and Description |
|---|---|
java.util.ArrayList<java.util.HashMap<java.lang.String,java.lang.String>> |
executeStatement(java.util.List<java.lang.String> columnName,
java.util.List<java.lang.String> tableName,
java.lang.String whereClause)
Method to construct SQL query based on the column names, table names and
where clause, and generates the output of the SQL query into a List
|
java.util.HashMap<java.lang.String,java.util.HashMap<java.lang.String,java.lang.String>> |
executeStatement(java.util.List<java.lang.String> columnName,
java.util.List<java.lang.String> tableName,
java.lang.String whereClause,
java.lang.String mapKey)
Method to construct SQL query based on the column names, table names,
where clause, and generates the output of the sql query into a Map with
the mapKey as the key
|
public CiscoLMSDatabaseAccessObject(java.lang.String host,
java.lang.String port,
java.lang.String dbName,
java.lang.String userName,
java.lang.String password,
java.lang.String databaseType,
java.lang.String connString)
host - The hostname/ip of the db to connect to the dbport - The port of the db to connect to the dbdbName - The db schema nameuserName - The userName to connect to the dbpassword - The password to connect to the dbdatabaseType - The databaseType string used to register the dbconnString - The connection string used to make connection via the jdbc
driverpublic java.util.HashMap<java.lang.String,java.util.HashMap<java.lang.String,java.lang.String>> executeStatement(java.util.List<java.lang.String> columnName,
java.util.List<java.lang.String> tableName,
java.lang.String whereClause,
java.lang.String mapKey)
columnName - The list of column names to be used in the SQL querytableName - The list of table names to be used in the SQL querywhereClause - The where clause to be used in the SQL querymapKey - The column to be used as key to the mappublic java.util.ArrayList<java.util.HashMap<java.lang.String,java.lang.String>> executeStatement(java.util.List<java.lang.String> columnName,
java.util.List<java.lang.String> tableName,
java.lang.String whereClause)
columnName - The list of column names to be used in the SQL querytableName - The list of table names to be used in the SQL querywhereClause - The where clause to be used in the SQL query