{"action":"created","issue":{"url":"https://api.github.com/repos/php/php-src/issues/2010","repository_url":"https://api.github.com/repos/php/php-src","labels_url":"https://api.github.com/repos/php/php-src/issues/2010/labels{/name}","comments_url":"https://api.github.com/repos/php/php-src/issues/2010/comments","events_url":"https://api.github.com/repos/php/php-src/issues/2010/events","html_url":"https://github.com/php/php-src/pull/2010","id":166472750,"number":2010,"title":"Php 7.0.9 - Fix PostgreSQL \"Object not in prerequisite state: 7 ERROR: currval of sequence sequence_name is not yet defined in this session\"","user":{"login":"phackwer","id":4871786,"avatar_url":"https://avatars.githubusercontent.com/u/4871786?v=3","gravatar_id":"","url":"https://api.github.com/users/phackwer","html_url":"https://github.com/phackwer","followers_url":"https://api.github.com/users/phackwer/followers","following_url":"https://api.github.com/users/phackwer/following{/other_user}","gists_url":"https://api.github.com/users/phackwer/gists{/gist_id}","starred_url":"https://api.github.com/users/phackwer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phackwer/subscriptions","organizations_url":"https://api.github.com/users/phackwer/orgs","repos_url":"https://api.github.com/users/phackwer/repos","events_url":"https://api.github.com/users/phackwer/events{/privacy}","received_events_url":"https://api.github.com/users/phackwer/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-20T01:05:14Z","updated_at":"2016-07-20T02:00:05Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/php/php-src/pulls/2010","html_url":"https://github.com/php/php-src/pull/2010","diff_url":"https://github.com/php/php-src/pull/2010.diff","patch_url":"https://github.com/php/php-src/pull/2010.patch"},"body":"This PR fixes a very disturbing bug that happens when currval is used before an insert.\r\n\r\nFor versions prior to server_version_num 080100, the only option was to use currval. Some frameworks had problems with their ORMs, such as Symfony/Doctrine, Drupal and PhalconPHP. The message currently received is:\r\n\r\n\"Object not in prerequisite state: 7 ERROR: currval of sequence sequence_name is not yet defined in this session\"\r\n\r\nAnd it's quite difficult to reproduce, since it happens on some circular references ORMs are unable to handle.\r\n\r\nFor later versions of PostgreSQL, the most correct way to the an sequence last value is to use postgres lastval() function.\r\n\r\nHere are some references:\r\n\r\nhttps://www.drupal.org/node/1807356\r\nphalcon/cphalcon#1134\r\nhttp://issuehub.io/?label%5B%5D=pdo_pgsql\r\ndoctrine/dbal#2329"},"comment":{"url":"https://api.github.com/repos/php/php-src/issues/comments/233818504","html_url":"https://github.com/php/php-src/pull/2010#issuecomment-233818504","issue_url":"https://api.github.com/repos/php/php-src/issues/2010","id":233818504,"user":{"login":"phackwer","id":4871786,"avatar_url":"https://avatars.githubusercontent.com/u/4871786?v=3","gravatar_id":"","url":"https://api.github.com/users/phackwer","html_url":"https://github.com/phackwer","followers_url":"https://api.github.com/users/phackwer/followers","following_url":"https://api.github.com/users/phackwer/following{/other_user}","gists_url":"https://api.github.com/users/phackwer/gists{/gist_id}","starred_url":"https://api.github.com/users/phackwer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phackwer/subscriptions","organizations_url":"https://api.github.com/users/phackwer/orgs","repos_url":"https://api.github.com/users/phackwer/repos","events_url":"https://api.github.com/users/phackwer/events{/privacy}","received_events_url":"https://api.github.com/users/phackwer/received_events","type":"User","site_admin":false},"created_at":"2016-07-20T02:00:05Z","updated_at":"2016-07-20T02:00:05Z","body":"It took me sometime because the connection from PDOTest is refusing password supplied only on the DSN. "}}
{"actor":{"display_login":"phackwer"}}