public class MDXOlap4jConnection extends Object implements org.pentaho.commons.connection.IPentahoConnection
Modifier and Type | Field and Description |
---|---|
protected org.olap4j.OlapConnection |
connection
Underlying connection to OLAP system.
|
CLASSNAME_KEY, CONNECTION, CONNECTION_NAME, DRIVER_KEY, HQL_DATASOURCE, JNDI_NAME_KEY, KEYS, LOCATION_KEY, MDX_DATASOURCE, MDX_OLAP4J_DATASOURCE, NONE_DATASOURCE, PASSWORD_KEY, PROVIDER, QUERY_KEY, SQL_DATASOURCE, USERNAME_KEY, XML_DATASOURCE
Constructor and Description |
---|
MDXOlap4jConnection() |
Modifier and Type | Method and Description |
---|---|
void |
clearWarnings()
Clears any warnings cached by the connection.
|
void |
close()
Closes the connection.
|
boolean |
connect(Properties props)
Sets the properties to be used when the connection is made.
|
org.pentaho.commons.connection.IPentahoResultSet |
executeQuery(String arg0)
Executes the specified query against the connection.
|
org.olap4j.OlapConnection |
getConnection()
Returns the underlying connection to OLAP system.
|
String |
getDatasourceType()
Returns the type of connection.
|
String |
getLastQuery()
Retrieves the string representation of the last executed query.
|
org.pentaho.commons.connection.IPentahoResultSet |
getResultSet()
Returns resultset of the last executed query.
|
boolean |
initialized()
Checks if the connection is initialized or not.
|
boolean |
isClosed()
Checks if the connection is closed or not.
|
boolean |
isReadOnly()
Checks if the connection is read only or not.
|
org.pentaho.commons.connection.IPentahoResultSet |
prepareAndExecuteQuery(String arg0,
List arg1)
Builds the query based on the pattern and parameters list and executes it against the connection.
|
boolean |
preparedQueriesSupported()
Checks if the given connection supports prepared queries.
|
void |
setFetchSize(int arg0)
Sets size of the fetch buffer used when retrieving rows from the underlying database.
|
void |
setMaxRows(int arg0)
Sets maximum rows that will be returned by the next query.
|
void |
setProperties(Properties props)
Sets the properties to be used when the connection is made.
|
protected org.olap4j.OlapConnection connection
public void close()
close
in interface org.pentaho.commons.connection.IPentahoConnection
public boolean connect(Properties props)
connect
in interface org.pentaho.commons.connection.IPentahoConnection
props
- Properties to be used for creating connection.
This particular method relies on the following properties: url, driver, user, password.public org.pentaho.commons.connection.IPentahoResultSet executeQuery(String arg0)
executeQuery
in interface org.pentaho.commons.connection.IPentahoConnection
query
- SQL-like query string. May be data source specific.public org.pentaho.commons.connection.IPentahoResultSet getResultSet()
getResultSet
in interface org.pentaho.commons.connection.IPentahoConnection
public boolean initialized()
initialized
in interface org.pentaho.commons.connection.IPentahoConnection
public boolean isClosed()
isClosed
in interface org.pentaho.commons.connection.IPentahoConnection
public boolean isReadOnly()
isReadOnly
in interface org.pentaho.commons.connection.IPentahoConnection
public org.pentaho.commons.connection.IPentahoResultSet prepareAndExecuteQuery(String arg0, List arg1) throws Exception
prepareAndExecuteQuery
in interface org.pentaho.commons.connection.IPentahoConnection
arg0
- SQL-like query string. May be data source specific.arg1
- List of objects to bind into prepared query.Exception
public boolean preparedQueriesSupported()
preparedQueriesSupported
in interface org.pentaho.commons.connection.IPentahoConnection
public void setFetchSize(int arg0)
setFetchSize
in interface org.pentaho.commons.connection.IPentahoConnection
fetchSize
- The buffer size.public void setMaxRows(int arg0)
setMaxRows
in interface org.pentaho.commons.connection.IPentahoConnection
maxRows
- Maximum rows that are returned by the next query.public void setProperties(Properties props)
setProperties
in interface org.pentaho.commons.connection.IPentahoConnection
props
- Properties to be used when the connection is made.public void clearWarnings()
clearWarnings
in interface org.pentaho.commons.connection.IPentahoConnection
public String getDatasourceType()
getDatasourceType
in interface org.pentaho.commons.connection.IPentahoConnection
public String getLastQuery()
getLastQuery
in interface org.pentaho.commons.connection.IPentahoConnection
public org.olap4j.OlapConnection getConnection()
Copyright © 2021 Hitachi Vantara. All rights reserved.