{"action":"created","issue":{"url":"https://api.github.com/repos/jOOQ/jOOQ/issues/4783","labels_url":"https://api.github.com/repos/jOOQ/jOOQ/issues/4783/labels{/name}","comments_url":"https://api.github.com/repos/jOOQ/jOOQ/issues/4783/comments","events_url":"https://api.github.com/repos/jOOQ/jOOQ/issues/4783/events","html_url":"https://github.com/jOOQ/jOOQ/issues/4783","id":120976865,"number":4783,"title":"SQL Exception during code generation (Postgres 9.3)","user":{"login":"ookke","id":237161,"avatar_url":"https://avatars.githubusercontent.com/u/237161?v=3","gravatar_id":"","url":"https://api.github.com/users/ookke","html_url":"https://github.com/ookke","followers_url":"https://api.github.com/users/ookke/followers","following_url":"https://api.github.com/users/ookke/following{/other_user}","gists_url":"https://api.github.com/users/ookke/gists{/gist_id}","starred_url":"https://api.github.com/users/ookke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ookke/subscriptions","organizations_url":"https://api.github.com/users/ookke/orgs","repos_url":"https://api.github.com/users/ookke/repos","events_url":"https://api.github.com/users/ookke/events{/privacy}","received_events_url":"https://api.github.com/users/ookke/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/jOOQ/jOOQ/labels/C:%20Code%20Generation","name":"C: Code Generation","color":"0000aa"},{"url":"https://api.github.com/repos/jOOQ/jOOQ/labels/P:%20Medium","name":"P: Medium","color":"ffaaaa"},{"url":"https://api.github.com/repos/jOOQ/jOOQ/labels/T:%20Defect","name":"T: Defect","color":"cccccc"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/jOOQ/jOOQ/milestones/119","html_url":"https://github.com/jOOQ/jOOQ/milestones/Version%203.8.0","labels_url":"https://api.github.com/repos/jOOQ/jOOQ/milestones/119/labels","id":1094772,"number":119,"title":"Version 3.8.0","description":"","creator":{"login":"lukaseder","id":734593,"avatar_url":"https://avatars.githubusercontent.com/u/734593?v=3","gravatar_id":"","url":"https://api.github.com/users/lukaseder","html_url":"https://github.com/lukaseder","followers_url":"https://api.github.com/users/lukaseder/followers","following_url":"https://api.github.com/users/lukaseder/following{/other_user}","gists_url":"https://api.github.com/users/lukaseder/gists{/gist_id}","starred_url":"https://api.github.com/users/lukaseder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lukaseder/subscriptions","organizations_url":"https://api.github.com/users/lukaseder/orgs","repos_url":"https://api.github.com/users/lukaseder/repos","events_url":"https://api.github.com/users/lukaseder/events{/privacy}","received_events_url":"https://api.github.com/users/lukaseder/received_events","type":"User","site_admin":false},"open_issues":363,"closed_issues":63,"state":"open","created_at":"2015-05-04T10:29:41Z","updated_at":"2015-12-08T12:35:18Z","due_on":null,"closed_at":null},"comments":2,"created_at":"2015-12-08T10:17:20Z","updated_at":"2015-12-08T12:38:21Z","closed_at":null,"body":"This exception appeared after upgrading from jOOQ 3.5.4 code generator to 3.7.1. We are using Postgres 9.3, I'm a bit puzzled because:\r\n\r\na) the query has a where 1=0 clause which will cause it to never return anything\r\n\r\nb) I checked the information_schema.parameters table in our db and indeed it doesn't have a parameter_default column, is the jooq postgres meta schema based on a newer postgres version where this was added or?\r\n\r\n```\r\nSQL exception            : Exception while executing meta query: ERROR: column parameters.parameter_default does not exist\r\n  Position: 8\r\n\r\nPlease report this bug here: https://github.com/jOOQ/jOOQ/issues/new\r\n\r\nselect \"information_schema\".\"parameters\".\"parameter_default\"\r\nfrom \"information_schema\".\"parameters\"\r\nwhere 1 = 0\r\n```"},"comment":{"url":"https://api.github.com/repos/jOOQ/jOOQ/issues/comments/162868235","html_url":"https://github.com/jOOQ/jOOQ/issues/4783#issuecomment-162868235","issue_url":"https://api.github.com/repos/jOOQ/jOOQ/issues/4783","id":162868235,"user":{"login":"lukaseder","id":734593,"avatar_url":"https://avatars.githubusercontent.com/u/734593?v=3","gravatar_id":"","url":"https://api.github.com/users/lukaseder","html_url":"https://github.com/lukaseder","followers_url":"https://api.github.com/users/lukaseder/followers","following_url":"https://api.github.com/users/lukaseder/following{/other_user}","gists_url":"https://api.github.com/users/lukaseder/gists{/gist_id}","starred_url":"https://api.github.com/users/lukaseder/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lukaseder/subscriptions","organizations_url":"https://api.github.com/users/lukaseder/orgs","repos_url":"https://api.github.com/users/lukaseder/repos","events_url":"https://api.github.com/users/lukaseder/events{/privacy}","received_events_url":"https://api.github.com/users/lukaseder/received_events","type":"User","site_admin":false},"created_at":"2015-12-08T12:38:21Z","updated_at":"2015-12-08T12:38:21Z","body":"Thanks for reporting. This is a check that we run to see if the relevant column exists. The 1=0 predicate is there to prevent results, we don't care about results, we only care about the exception. \r\n\r\nSee:\r\nhttps://github.com/jOOQ/jOOQ/blob/version-3.7.1/jOOQ-meta/src/main/java/org/jooq/util/postgres/PostgresRoutineDefinition.java#L153\r\n\r\nHowever, you shouldn't see that exception in your logs, though. It's a perfectly accepted situation. We'll investigate why this shows up in your logs."}}