passing postgres id for all objects