Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## toolkit.db.api
Interface SQLStmtCreator

    public interface SQLStmtCreator

Normally, you import tables/views from DB to JReort Catalog and then build PSQL queries based on those imported tables/views using JReport Query Editor. You can define search conditions and joins among tables/views using JReport Query Editor. At runtime, JReport Engine will execute those queries and fetch data from those tables/views. But sometimes you may want to re-specify those information at runtime, for example, fetching data from other tables instead of those imported tables/views in JReport Catalog, re-defining some search conditions or joins, etc. API `SQLStmtCreator` gives you the chance to do so.
If you implement this interface and enable a PSQL query to get SQL statement from users, JReport Engine will ask you to create the SQL statement that will be passed to DB by calling `SQLStmtCreator.getSQLStmt(QueryInfo)`.
Note: in order to use Class.forName() to create a new Class instance for the class implemented SQLStmtCreator, any implemented class must have a default constructor.

Method Summary
`java.lang.String` | `getSQLStmt(QueryInfo psqlQueryInfo)` Creates an SQL statement string.

Method Detail

### getSQLStmt

    java.lang.String getSQLStmt(QueryInfo psqlQueryInfo)

  Creates an SQL statement string.

  Parameters:
    `psqlQueryInfo` - The psql query information, based on which SQL string is to be created.
  Returns:
    SQL statement string that will be passed to DB. `#QueryInfo`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD