[eluser]tolyx[/eluser]
Well it was set to non-NULL, but that doesn't matter since the save is just an UPDATE (i.e. from 0 to whatever the id is). And as per my message earlier, removing the validation rule allows the work_example to be saved perfectly. So it seems something's gone awry in the validation... as though it is resetting the $portfolio object to NULL just as it is saved...?