Class BooleanAndStatement<P extends WhereStatement>

java.lang.Object
com.invirgance.convirgance.jdbc.sql.WhereStatement
com.invirgance.convirgance.jdbc.sql.BooleanAndStatement<P>
Type Parameters:
P - The parent WhereStatement type this returns to when done.
All Implemented Interfaces:
ComparisonStatement, SQLStatement

public class BooleanAndStatement<P extends WhereStatement> extends WhereStatement implements ComparisonStatement
Creates a logical AND grouping in SQL, combining multiple conditions that all must be true. This wraps conditions in parentheses and joins them with AND keywords.

 DatabaseSchemaLayout layout = getHSQLLayout();
 Table table = layout.getCurrentSchema().getTable("customer");
 
 SQLStatement query = table
     .select()
     .column(table.getColumn("name"))
     .where()
         .equals(column, value)
         .and() // BooleanAndStatement
             .greaterThan(table.getColumn("height"), value)
             .lessThan(table.getColumn("maximum"), value)
         .end()
     .done();
 
Author:
jbanes