$this->whereAdd("{$joinAs}.{$kSql} = {$obj->$k}");
continue;
}
+ + if (is_a($obj->$k,'DB_DataObject_Cast')) {
+ $value = $obj->$k->toString($v,$DB);
+ if (PEAR::isError($value)) {
+ $this->raiseError($value->getMessage() ,DB_DATAOBJECT_ERROR_INVALIDARG);
+ return false;
+ }
+ if (strtolower($value) === 'null') {
+ $obj->$k = 'null';
I've changed this to
$this->whereAdd("{$joinAs}.{$kSql} IS NULL");
as I suspect that is what it was supposed to be..
Regards
Alan
+ } else {
+ $this->whereAdd("{$joinAs}.{$kSql} = $value");
+ continue;
+ }
+ }
+ /* this is probably an error condition! */
$this->whereAdd("{$joinAs}.{$kSql} = 0");
}