Sun StorageTek 5800 System Client API Reference Manual

Dynamic Parameters

5800 system queries allow dynamic parameters. A dynamic parameter is indicated by the presence of a question mark in the query string (for example, the query name=? AND address=?). The bindParameter call is used in Java to bind typed values for use in place of the question marks.

For the Java API, the syntax is:

     import com.sun.honeycomb.client.PreparedStatement;
     import com.sun.honeycomb.client.QueryResultSet;
     Date date_value= new Date();
     PreparedStatement stmt = new PreparedStatement(
     QueryResultSet qrs = query(stmt);

For further information, see query (with PreparedStatement), query (with PreparedStatement and selectKeys) and PreparedStatement.