I was reading into why this may be caused in postgresql, and I can only guess since I cant read the code, however, it seems postgres needs to explicitly have a RETURN element to any insert or update (or delete i would assume)
the code would need to be like
INSERT INTO persons...