Override log_min_error_statement per sqlstate.

Allow the default log_min_error_statement to be overridden per sqlstate to
make it possible to not log statements causing some error types while
maintaining a low log_min_error_statement or enable statement logging for
some error types when the default is to not log any statements.

(cherry picked from commit 7ce03d90568da0911f93bd821abe00f7c3fbb2c4)