![]() ![]() ![]() ![]() ![]() ![]() |
Applications can access data services through SQL. This is necessary in the case of many reporting tools such as Crystal Reports, Hyperion, and Business Objects. But the ability to handle SQL is also useful in other contexts.
For example, it is useful to be able to run ad hoc SQL queries against data services using tools such as DbVisualizer. Application developers also can use a standalone Query Plan Viewer utility which supports both XQuery and SQL.
BEA AquaLogic Data Services Platform supports table parameters, an extension to SQL-92.
SQL access is provided through the AquaLogic Data Services Platform JDBC driver. The driver implements the java.sql.* interface in JDK 1.4x to provide access to an AquaLogic Data Services Platform server through the JDBC interface. You can use the JDBC driver to execute SQL92 SELECT queries, or stored procedures over AquaLogic Data Services Platform applications.
This chapter explains how to use SQL to access data services as well as how to set up and use the AquaLogic Data Services Platform JDBC driver. It covers the following topics:
Note: | For data source and configuration pool information, refer to the WebLogic Administration Guide: |
Note: |
http://download.oracle.com/docs/cd/E13196_01/platform/docs81/admin/index.html |
To access data services through SQL, data service functions first need to be published as SQL objects through a JDBC interface. These SQL objects include tables, stored procedures, and functions.
Note: | SQL objects published through AquaLogic Data Services Platform need to be enclosed in double quotes when used in an SQL query, if the object name contains a hyphen. |
To publish data service functions as SQL Objects, the following tasks need to be performed:
Once deployed, the newly created SQL objects are available to your application through standard JDBC.
Techniques for publishing data services as SQL are described in Publishing Data Services Functions for SQL Use in the Data Services Developer's Guide.
Note: | For details on accessing the AquaLogic Data Services Platform JDBC driver, and information on the relationship between data services artifacts and JDBC, see About the AquaLogic Data Services Platform JDBC Driver. |
Built-in or custom functions in your database can be made available through data services once the function has been registered with AquaLogic Data Services Platform through a library. For more information about using database functions with AquaLogic Data Services Platform, refer to Creating and Working with XQuery Function Libraries in Data Services Developer's Guide.
This section outlines the SQL-92 support in the AquaLogic Data Services Platform JDBC driver.
The AquaLogic Data Services Platform JDBC driver provides SQL-92 support for the SELECT statement. INSERT, UPDATE, and DELETE statements are not supported. DDL (Data Definition Language) statements are also not supported.
The AquaLogic Data Services Platform JDBC driver implements the following interfaces from java.sql
package specified in JDK 1.4x:
The following limitations are known to exist in the AquaLogic Data Services Platform JDBC driver:
The following table (Table 5-1) notes additional limitations that apply to SQL language features.
Table parameters extend SQL-92 by providing the ability to add parameters to SQL FROM clauses. For example, in SQL you can encounter a situation where it is necessary to code an exact number of parameters (highlighted) into a query.
In the following query test.rtlall.CUSTOMER is the entire customer table.
SELECT cust.CUSTOMER_ID, cust.FIRST_NAME, cust.LAST_NAME
FROM test.rtlall.CUSTOMER cust
where cust.CUSTOMER_ID in (?, ?, ?, ...)
and cust.LAST_NAME in (?, ?, ?, ... )
If a large number of parameters are involved, data entry can be slow and setting up the SQL statement tedious.
Table parameters provide an alternative. The following query uses table parameters (highlighted):
SELECT cust.CUSTOMER_ID, cust.FIRST_NAME, cust.LAST_NAME
FROM ? as id_cust(id_cust_num), test.rtlall.CUSTOMER as cust ,
? as id_cust(last_name)
WHERE id_cust.id_cust_num = cust.CUSTOMER_ID
and cust.LAST_NAME = id_cust.last_name
The table parameter is specified through the same mechanism as a a parameter; a question mark ("?") is used in place of the appropriate table name.
Note: | In the current implementation only a single table column can be passed as a table parameter. If more than one column is specified, an exception is thrown. |
A scenario: a data service contains consolidated information on all recent customer orders. A sales manager has a consolidated list of all government customers in European countries. The goal is to use a data service to obtain order information for that specific set of customers.
Stepping back from the example it is easy to see the that the scenario is a common one: a join between the manager's customer list and order information. However, if the manager's customer list is long and not already available through a database, it would be convenient to be able to pass in a list of values as if it were a column in a table.
In the SQL cited above a list of customers is passed in as a table with a single column. The clause:
? as id_cust(id_cust_num)
provides a virtual table value (id_cust) and a virtual column name (id_cust_num).
Although aliasing is not mandatory, it is generally recommended since default parameter column names follow numerical sequence (0, 1, and so forth) and as such are subject to unexpected name conflicts.
The one case where defaults are appropriate is when wildcards are employed such as:
select * from ?
and other simple cases involving wildcards.
Table parameters are passed to data services through the AquaLogic Data Services Platform JDBC driver, specifically through its TableParameter class. The class (shown in its entirety in Listing 5-1) represents an entire table parameter as well as the rows it represents.
public class TableParameter implements Serializable {
/**
* Constructor
*
* @schema the schema for the table
*/
public TableParameter(ValueType[] schema);
/**
* Creates a new a row and adds it to the list of rows in this table
*/
public Row createRow();
/**
* Gets the rows of this table
*/
public List/*Row*/ getRows();
/**
* Gets the schema of this table
*/
public ValueType[] getSchema();
/**
* Represents a row in the table
*/
public class Row implements Serializable {
/**
* Sets a value to a particular column
* @param colIdx the index of the column to set
* @param val the value for the column
* @exception if index is out of bounds
*/
public void setObject(int colIdx,Object val) throws SQLException;
Object getObject(int colIdx);
}
The following steps show how to create a TableParameter class:
Note: | At present only one column is supported. |
TableParameters are passed through JDBC just like any other parameter, through a PreparedStatement.
For example, you would first create a PreparedStatement with the query:
SELECT cust.CUSTOMER_ID, cust.FIRST_NAME, cust.LAST_NAME
FROM ? as id_cust(id_cust_num), test.rtlall.CUSTOMER as cust ,
? as id_cust(last_name)
WHERE id_cust.id_cust_num = cust.CUSTOMER_ID
and cust.LAST_NAME = id_cust.last_name
and cust.ORDER_AMT > ?
Float orderAmt = new Float(75f)
setObject(3,orderAmt)
This sets the value for the third parameter (the parameter in the WHERE clause).
setObject(2,y)
setObject(1,z)
to set the value for the table parameter. The "y" and "z" values should be of the type TableParameter.
The following simplified example illustrates the use of a table parameter. An in-memory list contains three customers: CUST_1, CUST_2, and CUST_3.
SELECT cust.cust_num, order.item, order.price
FROM ? as cust(cust_num), Order as order
WHERE cust.cust_num = order.cust_id
The supporting JDBC code is shown in listing Listing 5-2:
//first create the table parameter
ValueType[] schemaList = new ValueType[1];
schemaList[0] = ValueType.REPEATING_VARCHAR_TYPE;
TableParameter tableParam = new TableParameter(schemaList);
// then create the rows in your virtual table
// (in practice you would read data in from a file
// or some other data stream)
TableParameter.Row row1 = tableParam.createRow();
row1.setObject(1," CUSTOMER _1");
TableParameter.Row row2 = tableParam.createRow();
Row2.setObject(1," CUSTOMER _2");
// repeat for second table parameter
// (...)
// execute the query
PreparedStatement objPreparedStatement = objConnection.prepareStatement(
"SELECT cust.CUSTOMER_ID, cust.FIRST_NAME, cust.LAST_NAME
FROM ? as id_cust(id_cust_num), test.rtlall.CUSTOMER as cust , ? as id_cust(last_name)
WHERE id_cust.id_cust_num = cust.CUSTOMER_ID
and cust.LAST_NAME = id_cust.last_name
and cust.ORDER_AMT > ? ");
// and set table parameters
objPreparedStatement.setObject(1,tableParam);
objPreparedStatement.setObject(2,tableParam2);
objResultSet = objPreparedStatement.executeQuery();
When data service information is accessed from a JDBC client, the data is mapped from its XML schema format to SQL types.
xmlns:xs="http://www.w3.org/2001/XMLSchema"
The Java types are defined by:
java.sql.Types
XML types that can be mapped to SQL Type Mappings are shown in Table 5-2.
The AquaLogic Data Services Platform JDBC driver enables JDBC and ODBC clients to access information available from data services using SQL. The JDBC driver increases the flexibility of the AquaLogic Data Services Platform integration layer by enabling access from database visualization and reporting tools, such as DbVisualizer, Crystal Reports, Hyperion, and Business Objects. For the client, the AquaLogic Data Services Platform integration layer appears as a relational database, with each data service function comprising a table. Internally, AquaLogic Data Services Platform translates SQL queries into XQuery.
Some constraints associated with the AquaLogic Data Services Platform JDBC driver include the following:
You can create flat views to be used from the JDBC driver to expose non-flat data services,.
This section discusses the SQL Name Mapping technique used to map SQL functions to AquaLogic Data Services Platform functions, along with the steps to configure the JDBC Driver connection using Java and non-Java applications. It includes the following topics:
The AquaLogic Data Services Platform JDBC driver has the following features:
Using AquaLogic Data Services Platform JDBC Driver, you can control the metadata accessed through SQL based on the access rights set at the JDBC driver level. This ensures that authorized users can view only those tables and procedures, which they are authorized to access. However, to be able to use this feature, the AquaLogic Data Services Platform console configuration should be set to check access control. For more information, refer to the " Securing Data Services Platform Resources" section in the Administration Guide.
Xerces Java - 2.6.2 : xercesImpl.jar
, xmlParserAPIs.jar
, and ANTLR 2.7.4 : antlr.jar
.wlclient.jar
, ld-client.jar
, Schemas_UNIFIED_Annotation.jar
, jsr173_api.jar
, and xbean.jar
.sAquaLogic Data Services Platform views data retrieved from a database in the form of data sources and functions. The following table (Table 5-3) shows the equivalent terminology.
For example, if you have a project TestDataServices
and CUSTOMERS.ds
with a function getCustomers()
under the schema MySchema
, then you can map getCustomers
as an SQL object as follows:
TestDataServices.MySchema.getCustomer
where TestDataServices
is the catalog and MySchema
is the name of the schema folder. This mapping is based on mapping the AquaLogic Data Services Platform functions to SQL objects. For more information about mapping AquaLogic Data Services Platform functions as SQL objects, refer to
Publishing Data Services Functions for SQL Use in the Data Services Developer's Guide.
AquaLogic Data Services Platform supports many functions that can be used to access data services through various reporting tools. In the following tables functions are divided into the following types:
CEIL returns the smallest integer greater than or equal to n. If n is NULL, the return value is NULL. |
||
The following numeric operation functions are provided:
The following string management functions are provided:
The following datetime functions are provided:
The following aggregation functions are provided:
The AquaLogic Data Services Platform JDBC driver supports standard JDBC API search patterns, as shown in Table 5-8.
Assuming that the default_catalog is catalog1 and default_schema is schema1, Table 5-9 shows some common matching patterns.
AquaLogic Data Services Platform JDBC driver is located in an archive file named ldjdbc.jar
, which is available in the following directory after you install BEA AquaLogic Data Services Platform:
<bea_home>\weblogic81\liquiddata\lib\
To use the AquaLogic Data Services Platform JDBC driver on a client computer, you need to configure the classpath, class name, and the URL for the JDBC driver. To configure the driver on a client computer, perform the following steps:
ldjdbc.jar
and weblogic.jar
to the client computer.ldjdbc.jar
and weblogic.jar
to the computer's classpath. %JAVA_HOME%\jre\bin
to your path.com.bea.dsp.jdbc.driver.DSPJDBCDriver
jdbc:dsp@<DSPServerName>:<DSPServerPortNumber>/<DSPApplicationName>]
For example the driver URL would be:
jdbc:dsp@localhost:7001/RTLApp
jdbc:dsp@<DSPServerName>:<DSPServerPortNumber>/<DSPApplicationName>/<catalogname>/<schemaname>
Note: | If you do not specify the CatalogName and SchemaName in the JDBC driver URL, then you need to specify the three-part name for all queries. For example: |
select * from <catalogname>.<schemaname>.CUSTOMER
logFile
property. To log debugging information, use the following JDBC driver URL syntax:jdbc:dsp@localhost:7001/test;logFile=c:\output.txt
In this case, the log file will be created in c:\output.txt
. You can also specify the debug property separately instead of specifying it with the URL.
Note: | If you build a SQL query using a reporting tool, the unqualified JDBC function name is used in the generated SQL. Consequently, when an application developer invokes an XFL database function, the default catalog and schema name must be defined in the JDBC connection URL. It is also a requirement that any JDBC connection utilize those functions available from a single SQL catalog:schema pair location. |
The following is an example URL defining a default catalog and schema for a JDBC connection:
Note: | If application , default_catalog , or default_schema appears in both the connection properties and the URL, the one in the URL takes precedence. |
You can configure the JDBC driver connection using the properties object as follows:
props.put("user", "weblogic");
props.put("password", " weblogic ");
props.put("application", "RTLApp");
Connection objConnection = DriverManager.getConnection("jdbc:dsp@localhost:7001", props);
Note: | You can specify the default schema and catalog name using the default_catalog and default_schema property fields in case you do not specify it in the properties. |
Alternatively, you can specify the AquaLogic Data Services Platform application name, RTLApp, in the connection object itself, as shown in the following snippet:
props.put("user", " weblogic");
props.put("password", " weblogic ");
Connection objConnection = DriverManager.getConnection("jdbc:dsp@localhost:7001/RTLApp",props);
You can also configure the JDBC driver connection without creating a properties object, as shown in the following code:
Connection objConnection =
DriverManager.getConnection("jdbc:dsp@localhost:7001/RTLApp;logFile=c:\output.txt; ", <username>, <password>);
The steps to connect an application to AquaLogic Data Services Platform as a JDBC/SQL data source are substantially the same as connecting to any JDBC/SQL data source directly. In the database URL, use the AquaLogic Data Services Platform application name as the database identifier with "dsp" as the sub-protocol, in the form:
jdbc:dsp@
<WLServerAddress>:<WLServerPort>/<DSPApplicationName>
jdbc:dsp@localhost:7001/RTLApp
The name of the AquaLogic Data Services Platform JDBC driver class is:
com.bea.dsp.jdbc.driver.DSPJDBCDriver
This section describes how to connect using the driver class in a client application.
A JDBC client application can connect to a deployed AquaLogic Data Services Platform application in the same way as it can connect to any database. It loads the AquaLogic Data Services Platform JDBC driver and then establishes a connection to AquaLogic Data Services Platform.
Properties props = new Properties();
props.put("user", "weblogic");
props.put("password", "weblogic");
props.put("application", "RTLApp");
// Load the driver
Class.forName("com.bea.dsp.jdbc.driver.DSPJDBCDriver");
//get the connection
Connection con = DriverManager.getConnection("jdbc:dsp@localhost/7001", props);
The storedQueryWithParameters
method explained in this section, demonstrates how to use the preparedStatement interface using a connection object (con
). It is a valid connection obtained through the java.sql.Connection
interface to the WebLogic Server, which hosts AquaLogic Data Services Platform.
Note: | You can create a preparedStatement for a non-parametrized query as well. The statement can also be used in the same manner. |
In the method, CUSTOMER
refers to CUSTOMER.ds
.
public ResultSet storedQueryWithParameters() throws java.sql.SQLException
{
PreparedStatement preStmt =
con.prepareStatement (
"SELECT * FROM DataServices.MySchema.CUSTOMER WHERE CUSTOMER.LAST_NAME=?");
preStmt.setString(1,"SMITH");
ResultSet res = preStmt.executeQuery();
return res;
}
In the SELECT query, DataServices
is the catalog name and MySchema
is the name of the schema folder.
Note: | To use the CUSTOMER table in the SELECT query, you must first map it as an SQL Object. For details, refer to Publishing Data Service Functions As SQL on page 5-2. |
Once a connection is established to a server where AquaLogic Data Services Platform is deployed, you can call a data service function to obtain data by using a parameterized data service function call.
The following method demonstrates calling a stored query with a parameter (where con
is a connection to the AquaLogic Data Services Platform server obtained through the java.sql.Connection
interface). In the snippet, a stored query named dtaQuery
is executed where custid
is the parameter name and CUSTOMER2
is the parameter value.
public ResultSet storedQueryWithParameters(String paramName)
throws java.sql.SQLException {
//prepare a stored query to execute
con.prepareCall("call DataServices.MySchema.getCustomerById(?) ");
call.setString(1, "CUSTOMER2");
ResultSet resultSet = call.executeQuery();
return resultSet;
Note: | You can also use the prepareCall method as follows: |
con.prepareCall(" { call DataServices.MySchema.getCustomerById(?)}");
You can also use the AquaLogic Data Services Platform JDBC driver from client Java applications. This is a good way to learn how AquaLogic Data Services Platform exposes its artifacts through its JDBC/SQL driver.
This section describes how to connect to the driver from DBVisualizer. Figure 5-1 shows a sample application as viewed from DbVisualizer.
To use DBVisualizer, perform the following steps:
ldjdbc.jar
exists in your CLASSPATH. ldjdbc.jar
listed.ldjdbc.jar
from the list and then select Find Drivers from the Edit menu of the driver manager. The Driver Manager will detect the com.bea.dsp.jdbc.driver.DSPJDBCDriver
JDBC driver and display it in the list box.com.bea.dsp.jdbc.driver.DSPJDBCDriver
, from drop down list.jdbc:dsp@<machine_name>:<port>/<app_name>
. For example "jdbc:dsp@localhost:7001/RTLApp"
Once you have configured your ODBC-JDBC Bridge, you can use your application to access the data source presented by AquaLogic Data Services Platform. The usual reason for doing so is to connect AquaLogic Data Services Platform to the reporting tool that you need to use.
You can use an ODBC-JDBC bridge to connect to AquaLogic Data Services Platform JDBC driver from non-Java applications. This section describes how to configure the OpenLink and EasySoft ODBC-JDBC bridges to connect non-Java applications to the AquaLogic Data Services Platform JDBC driver.
The Openlink ODBC-JDBC driver can be used to interface with the AquaLogic Data Services Platform JDBC driver to query AquaLogic Data Services Platform applications with client applications, such as Crystal Reports 10, Business Objects 6.1, and MS Access 2003.
To use the OpenLink bridge, you will need to install the bridge and create a system DSN using the bridge. The following are the steps for these two tasks:
http://download.openlinksw.com/download/login.vsp?pform=2&pfam=1&pcat=1&prod=odbc-jdbc-bridge-st&os=i686-generic-win-32&os2=i686-generic-win-32&release-dbms=6.0-jdbc
WARNING: | For Windows platforms, be sure to save the value of your CLASSPATH before installation. |
ldjdbc.jar
and weblogic.jar
. A typical CLASSPATH might look like:D:\lddriver\ldjdbc.jar; D:\bea\weblogic81\server\lib\weblogic.jar;
D:\odbc-odbc\openlink\jdk1.4\opljdbc3.jar; D:\odbc-jdbc\openlink\jdk1.4\megathin3.jar;
jvm.dll
, which should be under your %javaroot%\jre\bin\server
directory.com.bea.dsp.jdbc.driver.DSPJDBCDriver.
Enter the following in the URL string field:
jdbc:dsp@<machine_name>:<port>/<app_name>/<catalogname>/<schemaname>
Applications can also communicate with the AquaLogic Data Services Platform JDBC Driver using EasySoft's ODBC-JDBC Gateway. The installation and use of the EasySoft Bridge is similar to the OpenLink bridge discussed in the previous section.
To use the EasySoft bridge, perform the following steps:
For classpath, enter the absolute path to the ldjdbc.jar
jdbc:dsp@<machine_name>:<port>/<app_name>/<catalogname>/<schemaname>
jdbc:dsp@localhost:7001/DataServices/Evaluation/NewSchema;logFile=c:\jdbc.log
com.bea.dsp.jdbc.driver.DSPJDBCDriver
This section describes how to configure the following reporting tools to use the AquaLogic Data Services Platform ODBC-JDBC driver:
Note: | Some reporting tools issue multiple SQL statement executions to emulate a scrollable cursor if the ODBC-JDBC bridge does not implement one. Some drivers do not implement a scrollable cursor, so the reporting tool issues multiple SQL statements. This can affect performance. |
This section describes the steps to connect Crystal Reports to the AquaLogic Data Services Platform JDBC driver along with information about standard configuration files that are available with AquaLogic Data Services Platform installation. It also describes the limitations of using Crystal Reports with AquaLogic Data Services Platform. It includes the following topics:
Before you start using Crystal Reports with AquaLogic Data Services Platform, you must modify the default Crystal Reports configuration file, CRConfig.xml
, to verify that Crystal Reports is able to access data services through JDBC.
The sample AquaLogic Data Services Platform CRConfig.xml
file is provided with the standard installation of AquaLogic Data Services Platform. The sections of the configuration file that need to be modified contain the string "ALDSP". This file is located at:
<weblogic81>/LiquidData/resources/ReportingToolConfigs/CrystalReports
You cannot use the sample CRConfig.xml
directly unless Crystal Reports is installed in the same directory as the path specified in the sample CRConfig.xml
and AquaLogic Data Services Platform is installed in the same directory as the path specified in the sample CRConfig.xml
. Therefore, you need to modify the default CRConfig.xml
file available with Crystal Reports according to the sample CRConfig.xml
file available with AquaLogic Data Services Platform.
Note: | Although you can modify the sample CRConfig.xml file available with AquaLogic Data Services Platform, it is recommended that you modify the default Crystal Reports CRConfig.xml file based on the sample file available with AquaLogic Data Services Platform. |
Table 5-10 identifies some restrictions and specifies configuration changes you need to make to your Crystal Reports configuration file when accessing data using the AquaLogic Data Services Platform JDBC driver.
The following code snippet is a sample of the <JDBC>
element with the JDBC driver URL and user name configuration settings:
<!-- ALDSP2.5 : The following <JDBC configuration is specific to ALDSP. -->
<JDBC>
<CacheRowSetSize>100</CacheRowSetSize>
<!-- ALDSP: Please replace <JDBCURL> with your URL. -->
<JDBCURL>jdbc:dsp@localhost:7001/YOUR_APP</JDBCURL>
<JDBCClassName>com.bea.dsp.jdbc.driver.DSPJDBCDriver</JDBCClassName>
<!-- ALDSP: Please replace <JDBCUserName> with your user name. -->
<JDBCUserName>ENTER_USER_NAME_HERE</JDBCUserName>
<JNDIURL></JNDIURL>
<JNDIConnectionFactory></JNDIConnectionFactory>
<JNDIInitContext>/</JNDIInitContext>
<JNDIUserName></JNDIUserName>
<GenericJDBCDriver>
<Option>Yes</Option>
<DatabaseStructure>catalogs,schemas,tables</DatabaseStructure>
<StoredProcType>Standard</StoredProcType>
<LogonStyle>Standard</LogonStyle>
</GenericJDBCDriver>
Before you use Crystal Reports to access data services, ensure that you consider the following facts:
To connect Crystal Reports to the JDBC driver and access data services to generate reports, perform the following steps:
Note: | The Database drop down box is populated with the available catalogs (AquaLogic Data Services Platform applications) once you have specified the correct parameters for User ID and Password as shown in Figure 5-3. |
Note: | This example chooses columns from the user-generated Command and the view CUSTOMER. |
Business Objects allows you to create a Universe and generate reports based on the specified Universe. In addition, you can execute pass-through SQL queries against Business Objects that do not need the creation of a Universe.
Note: | If you need to specify a four part name in a SELECT list (such as, <catalogname>.<schemaname>.<tablename>.<columnname> ), define a table alias using the FROM clause, and then use only two parts <tablealias>.<columnname> in the SELECT list. AquaLogic Data Services Platform JDBC driver extracts only the last two parts from the SELECT list item, and ignores the rest. |
Note: | For example: |
SELECT C.Name FROM DataServices.MySchema.CUSTOMER C
whereDataServices
is the catalog nameMySchema
is the schema nameCUSTOMER
is the table nameName
is the column nameC
is the table alias for CUSTOMER
This section provides information on configuring Business Objects to access the AquaLogic Data Services Platform JDBC driver. It includes the following topics:
There are two BusinessObjects configuration files, odbc.prm
and odbc.sbo
, available with the standard BusinessObjects installation, which need to be replaced with the odbc.prm
and odbc.sbo
configuration files available with AquaLogic Data Services Platform, to access data services using BusinessObjects.
When you install BusinessObjects, these files are copied to the following location:
<Business Objects Home >\BusinessObjects Enterprise 11.5\
win32_x86\dataAccess\connectionServer\odbc
With the AquaLogic Data Services Platform installation, these configuration files are available at the following location:
<weblogic81>/LiquidData/resources/ReportingToolConfigs/BusinessObjects
After installing AquaLogic Data Services Platform, save the original configuration files available with BusinessObjects at a different location and then replace them with the files packaged with AquaLogic Data Services Platform.
The BusinessObjects configuration files provided with AquaLogic Data Services Platform should be reviewed for comments. (Relevant comments contain the string "ALDSP").
Tip: | When first getting started using BusinessObjects with AquaLogic Data Services Platform, it is recommended that the included configuration file be used to verify your ability to access data services through JDBC. |
Table 5-11 identifies some restrictions and specifies configuration changes you may want to make to your BusinessObjects configuration files when accessing data using the AquaLogic Data Services Platform JDBC driver.
Before you start using Business Objects to access data services, ensure that you consider the following facts:
com.bea.ld.sql.compiler.ast.SQLTypeCheckingException: Invalid table reference. No such table null.Xtreme.CUSTOMER found.
at
com.bea.ld.sql.compiler.ast.TableRSN.inferSchemaAndCheck(Lcom/bea/ld/
sql/context/SQLContext;Lcom/bea/ld/sql/types/SchemaIndex;)V(TableRSN.java:149)
For details about configuring OpenLink, refer to Using OpenLink ODBC-JDBC Bridge on page 5-26.
To generate a report, perform the following steps:
Hyperion allows you to generate interactive and production reports using its Interactive Reporting Studio and Production Reporting Studio. This section describes the steps to access AquaLogic Data Services Platform data sources using an ODBC-JDBC bridge and generate interactive and production reports.
It includes the following topics:
Before you start using Hyperion to access data services, ensure that you consider the following facts:
Program type out of range
" error.To establish the connection and view results using the Hyperion Production Reporting Studio, perform the following steps:
Note: | To create reports using Hyperion Production Reporting Suite, you need to use lower case names for tables published in AquaLogic Data Services Platform. See Publishing Data Services Functions for SQL Use in Data Services Developer's Guide for further details on how tables are published in AquaLogic Data Services Platform. |
To generate reports using Interactive Reporting Studio, perform the following steps:
This section describes the procedure to connect Microsoft Access 2003 to AquaLogic Data Services Platform through an ODBC-JDBC bridge. It includes the following topics:
SQL_DECIMAL
and SQL_NUMERIC
fields to the closest Jet numeric data type depending upon the precision and scale of the ODBC field. In certain cases this results in mapping to a non-exact (floating point) numeric Jet data type, such as Double
or a Text field. For details, refer to the following Microsoft article:
http://support.microsoft.com/kb/214854/en-us
This implicit type conversion by MS Access causes some errors when retrieving data from AquaLogic Data Services Platform using MS Access.
To connect MS Access to the bridge, perform the following steps.
This section describes the procedure for connecting Microsoft Excel 2003 to AquaLogic Data Services Platform through an ODJB-JDBC bridge using EasySoft.
To connect MS Excel to AquaLogic Data Services Platform, perform the following steps:
When passing a generated SQL string to Excel, there are situations where Excel inserts single quotes around an alias, resulting in an exception from the AquaLogic Data Services Platform JDBC driver. Here is an example:
SELECT Sum(CREDIT.AMOUNT) AS 'Sum of AMOUNT' FROM Xtreme.CREDIT CREDIT
Although you can edit your query post-generation, another option is to install a patch from Microsoft which is designed to address the problem. The current URL for accessing information on this problem and patch is:
You can review the plan for the execution of a SQL query or XQuery using a standalone Query Plan Viewer utility. The functionality is similar to that described in "Using Query Plan View" in the Testing Query Plan Functions and Viewing Query Plans chapter of Data Services Developer's Guide.
Note: | In order to use this utility some components must be installed and an authorized log-in to an AquaLogic Data Services Platform-enabled application provided. |
In the absence of a full installation of AquaLogic Data Services Platform, a specific set of component files must be installed to run the Query Plan Viewer utility. Default locations for these are assumed, but these default can be easily modified.
You can adjust the default location settings by editing the aldspqpv.cmd
(Windows) or aldspqpv.sh
(unix/linux) files.
The command line syntax for the Query Plan Viewer utility is:
Java -classpath [path1/]wlclient.jar;[path2/]ldjdbc.jar;[path3/]aldspqpv.jar
com.bea.dsp.client.ui.shell.Shell
[Server host name][Server port number][Application name]
[User id][Password]
Here is an example using default settings:
Java -classpath ../../server/lib/wlclient.jar;../lib/ldjdbc.jar;../lib/aldspqpv.jar
com.bea.dsp.client.ui.shell.Shell
localhost 7001 RTLApp weblogic weblogic
Once your classpath is properly set you can invoke the Query Plan Viewer utility from the command-line using either:
On Windows systems you can easily associate the invocation command by associating a start menu option with aldspqpv.cmd
.
Before you can view query plans, you need to log in to an AquaLogic Data Services Platform-enabled server (Figure 5-25).
In the dialog enter the following information:
Once you have logged into the Query Plan Viewer, all information but the password is saved on your system.
Once you login to your server successfully, you are ready to enter a query by selecting whether to enter either an SQL query or an XQuery.
Note: | Functionally choosing XQuery or SQL Query is equivalent to selecting Ad hoc XQuery or Ad hoc SQL Query in Query Plan View in the data service development environment. |
For details on entering an XQuery or SQL Query and working with the resulting query plan, see Creating Ad Hoc Queries in the Data Services Developer's Guide.
The utility offers several options, available from its File menu. The options are described in Table 5-13.
![]() ![]() ![]() |