Trying to replicate the functionality of the dbobject embedding stuff.