|
Class Summary |
| SelectColumn |
This is the baseclass for TableColumn and (if supported in the future) ExpressionColumn |
| SortColumn |
A column in a sort directive. |
| SQLElementFactory |
|
| SQLJoin |
|
| SQLJoin.Path |
|
| SQLOrderByClause |
|
| SQLSelectColumn |
|
| SQLSelectFunction |
|
| SQLSelectStatement |
TODO - change to use Visitor pattern to allow for flexible SQL generation
TODO - add support for things like SELECT *, SELECT count(*)
TODO - add full support for joins in where clauses
TODO - allow better support for bound params |
| SQLUpdateStatement |
Defines a SQL update statement that allows data in a table to be selectively updated
Typical usage:
SQLWriter sqlWriter = new SQLWriterRegistry() ;
SQLUpdateStatement update = new SQLUpdateStatement(sqlWriter);
update.setTable("foo");
SQLWhereClauseElement where = new SQLFilterElement(sqlWriter, "foo", new String[]{"baz"}, new int[]{Types.VARCHAR}, Operators.EQUALS, new Object[]{"mars"});
update.setWhereClause(where);
update.addValue("txtcol", TypesProvider.ColumnType.VARCHAR, "hello world");
update.addValue("intcol", TypesProvider.ColumnType.INTEGER, new Integer(99));
String sql = instance.generateSql();
// now execute the SQL
Will generate SQL like this:
UPDATE foo
SET txtcol = 'hello world', intcol = 99
WHERE foo.baz = 'mars'
TODO: add the ability to use a join as part of the where statement - currently
this implementation is limited to columns within the table being updated |
| SQLWhereClauseCompositeElement |
|
| SQLWhereClauseInListElement |
|
| SQLWhereClauseLeafElement |
|
| SQLWhereClauseLeafElement.None |
|
| SQLWhereClauseStringElement |
A constant value to use in a where clause. |
| SQLWhereClauseTermElement |
Represents a simple SQL filter term. |
| TableColumn |
A column in table |