/**
* When updating the database, generate a string form of this object value
* that can be used in the WHERE clause to match the value in the database.
* A return value of null means that this column cannot be used in the WHERE
* clause, while a return of "null" (or "is null", etc) means that the column
* can be used in the WHERE clause and the value is actually a null value.
* This function must also include the column label so that its output
* is of the form:
* "columnName = value"
* or
* "columnName is null"
* or whatever is appropriate for this column in the database.
*/
/**
* When updating the database, generate a string form of this object value
* that can be used in the WHERE clause to match the value in the database.
* A return value of null means that this column cannot be used in the WHERE
* clause, while a return of "null" (or "is null", etc) means that the column
* can be used in the WHERE clause and the value is actually a null value.
* This function must also include the column label so that its output
* is of the form:
* "columnName = value"
* or
* "columnName is null"
* or whatever is appropriate for this column in the database.
*/
public String getWhereClauseValue(Object value, ISQLDatabaseMetaData md) {
if (value == null || value.toString() == null || value.toString().length() == 0)
return _colDef.getLabel() + " IS NULL";
else
// since we cannot do exact matches on floating point
// numbers, we cannot use this field in the WHERE clause.
//?? There does not seem to be any standard way to represent
//?? binary data in a WHERE clause...
return [[#variable1ce2e000]]; // tell caller we cannot use this in Where clause
// return _colDef.getLabel() + "=" + value.toString();
}
|