Class IsNullComparisonStatement
java.lang.Object
com.invirgance.convirgance.jdbc.sql.IsNullComparisonStatement
- All Implemented Interfaces:
ComparisonStatement,SQLStatement
- Direct Known Subclasses:
IsNotNullComparisonStatement
Represents the SQL "IS NULL" comparison operator in conditions.
This class creates SQL expressions that check whether a column or expression
is NULL (contains no value) in database queries.
DatabaseSchemaLayout layout = new DatabaseSchemaLayout(driver, getHSQLDataSource());
Table table = layout.getCurrentSchema().getTable("customer");
ExpressionStatement children = new ColumnExpressionStatement(layout, table.getColumn("children"));
IsNullComparisonStatement statement =
new IsNullComparisonStatement(layout, children);
- Author:
- jbanes
-
Constructor Summary
ConstructorsConstructorDescriptionCreates the statement using the provided database layout.IsNullComparisonStatement(DatabaseSchemaLayout layout, ExpressionStatement expression) Creates the statement using the provided layout and expression. -
Method Summary
Modifier and TypeMethodDescriptionReturns the current expression that will be evaluated in the query.If this statement is part of a larger statement, this returns the parent statement.render(SQLRenderer renderer) voidsetExpression(ExpressionStatement expression) Sets the expression to evaluate in the comparison.voidsetParent(SQLStatement parent) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.invirgance.convirgance.jdbc.sql.SQLStatement
query, query
-
Constructor Details
-
IsNullComparisonStatement
Creates the statement using the provided database layout.- Parameters:
layout- The layout.
-
IsNullComparisonStatement
Creates the statement using the provided layout and expression.- Parameters:
layout- The layout.expression- The expression.
-
-
Method Details
-
getParent
Description copied from interface:SQLStatementIf this statement is part of a larger statement, this returns the parent statement.- Specified by:
getParentin interfaceSQLStatement- Returns:
- the parent statement
-
setParent
- Specified by:
setParentin interfaceSQLStatement
-
getExpression
Returns the current expression that will be evaluated in the query.- Returns:
- ExpressionStatement
-
setExpression
Sets the expression to evaluate in the comparison.- Parameters:
expression- ExpressionStatement
-
render
- Specified by:
renderin interfaceSQLStatement
-