Overview | Package | Class | Tree | Deprecated | Index | Help
| SolarMetric Kodo JDO 2.5.8 generated on January 11 2004
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.solarmetric.kodo.impl.jdbc.sql
Class Select

    java.lang.Object
      |
      +--com.solarmetric.kodo.impl.jdbc.sql.SQLStatement
            |
            +--com.solarmetric.kodo.impl.jdbc.sql.Select

Direct Known Subclasses:
  ObjectSelect

public class Select
extends SQLStatement

Abstraction of a SQL SELECT statement.

Fields inherited from class com.solarmetric.kodo.impl.jdbc.sql.SQLStatement
`_dict, _resolver, _tables`

Constructor Summary
`Select(DBDictionary dict, ClassResolver resolver)`
`Select(Select copy, ClassResolver resolver)`

Method Summary
`void` | `clear()` Clear the WHERE clause and table list so that this statement can be reused.
`void` | `clearOrderBy()` Clear the ORDER BY columns.
`void` | `clearSelect()` Clear the select list of this statement.
`SQLBuffer` | `getOrderBy()` Return the ORDER BY values, or null if none.
`String[]` | `getSelects()` Return the selected columns, or null if none.
`SQLBuffer` | `getSQLBuffer()` Return the SQLBuffer to be used for exeucting the statement;
`boolean` | `isDistinct()` Return true if this is a DISTINCT query.
`boolean` | `isUpdate()` Return true if this is a FOR UPDATE query.
`boolean` | `isValid()` Return true if at least one table has been set for this SQL statement.
`Select` | `orderBy(Column col, boolean asc)` Add the given column to the list of those in the ORDER BY clause of this statement.
`Select` | `orderBy(SQLBuffer sql)` Order by the given SQL clause.
`(package private) Select` | `orderByInternal(String table, String column, boolean asc)`
`(package private) boolean` | `retainTableInWhere()` If true, when columns are mentioned in the WHERE clause, they will be in the form `table.column`.
`Select` | `select(Column col)` Add the given column to the list of those selected by this statement.
`Select` | `select(Column[] col)` Add the given columns to the list of those selected by this statement.
`Select` | `selectCount(Column col)` Select a count of the given column.
`Select` | `selectCount(Table table)` Select a count of the given table.
`Select` | `selectCount(Table table, boolean includeTable)` Select a count of the given table.
`(package private) Select` | `selectCountInternal(String table, String column, boolean includeTable)`
`(package private) Select` | `selectInternal(String table, String col)`
`Select` | `setDistinct(boolean val)` Make this into a SELECT DISTINCT query.
`Select` | `setUpdate(boolean val)` Make this into a SELECT FOR UPDATE query.

Methods inherited from class com.solarmetric.kodo.impl.jdbc.sql.SQLStatement
`and, clearTable, clearWhere, columnName, getClassResolver, getDictionary, getTables, getWhere, getWhereSize, not, or, popWhere, pushWhere, toString, where, where, where, where, where, where, where, where, where, where, whereInternal, whereInternal`

Methods inherited from class java.lang.Object
`, clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### Select

    public Select(DBDictionary dict,
                  ClassResolver resolver)

### Select

    public Select(Select copy,
                  ClassResolver resolver)

Method Detail

### setDistinct

    public Select setDistinct(boolean val)

  Make this into a SELECT DISTINCT query.

### isDistinct

    public boolean isDistinct()

  Return true if this is a DISTINCT query.

### setUpdate

    public Select setUpdate(boolean val)

  Make this into a SELECT FOR UPDATE query.

### isUpdate

    public boolean isUpdate()

  Return true if this is a FOR UPDATE query.

### select

    public Select select(Column col)

  Add the given column to the list of those selected by this statement. This will also add the column's table to those used by this statement.

### select

    public Select select(Column[] col)

  Add the given columns to the list of those selected by this statement. This will also add the columns' tables to those used by this statement.

### selectInternal

    Select selectInternal(String table,
                          String col)

### selectCount

    public Select selectCount(Table table)

  Select a count of the given table.

### selectCount

    public Select selectCount(Table table,
                              boolean includeTable)

  Select a count of the given table.

### selectCount

    public Select selectCount(Column col)

  Select a count of the given column.

### selectCountInternal

    Select selectCountInternal(String table,
                               String column,
                               boolean includeTable)

### getSelects

    public String[] getSelects()

  Return the selected columns, or null if none.

### clearSelect

    public void clearSelect()

  Clear the select list of this statement.

### orderBy

    public Select orderBy(SQLBuffer sql)

  Order by the given SQL clause.

### orderBy

    public Select orderBy(Column col,
                          boolean asc)

  Add the given column to the list of those in the ORDER BY clause of this statement. This will also add the column's table to those used by this statement.

### orderByInternal

    Select orderByInternal(String table,
                           String column,
                           boolean asc)

### getOrderBy

    public SQLBuffer getOrderBy()

  Return the ORDER BY values, or null if none.

### clearOrderBy

    public void clearOrderBy()

  Clear the ORDER BY columns.

### isValid

    public boolean isValid()

  Description copied from class: `SQLStatement`
  Return true if at least one table has been set for this SQL statement.
  Overrides:
    `isValid` in class `SQLStatement`

### clear

    public void clear()

  Description copied from class: `SQLStatement`
  Clear the WHERE clause and table list so that this statement can be reused.
  Overrides:
    `clear` in class `SQLStatement`

### getSQLBuffer

    public SQLBuffer getSQLBuffer()

  Description copied from class: `SQLStatement`
  Return the SQLBuffer to be used for exeucting the statement;
  Overrides:
    `getSQLBuffer` in class `SQLStatement`

### retainTableInWhere

    boolean retainTableInWhere()

  Description copied from class: `SQLStatement`
  If true, when columns are mentioned in the WHERE clause, they will be in the form `table.column`.
  Overrides:
    `retainTableInWhere` in class `SQLStatement`

Overview | Package | Class | Tree | Deprecated | Index | Help
| SolarMetric Kodo JDO 2.5.8 generated on January 11 2004
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright 2001,2002,2003 SolarMetric, Inc. All Rights Reserved.