src/bin/pg_dump/pg_dump.c happen to have hard-coded PUBLIC role name.
It completly breaks dumps when run with Turksh locale setting. In my
opinion making it lower-case would do much good and no harm. A mini
patch is given below.

On the other hand, I was thinking about wrapping all the identifiers in
dump files in single quotes. It is done in "SET SESSION AUTHORIZATION"
clause. Is there a reason for not doing this with table and colum names?

Regards,
Nic



 

*** ./src/bin/pg_dump/pg_dump.c.orig    Sun Dec  1 03:23:56 2002
--- ./src/bin/pg_dump/pg_dump.c Sun Dec  1 03:24:48 2002
***************
*** 4918,4924 ****
         * wire-in knowledge about the default public privileges for different
         * kinds of objects.
         */
!       appendPQExpBuffer(sql, "REVOKE ALL ON %s %s FROM PUBLIC;\n",
                                          type, name);
  
        /* Make a working copy of acls so we can use strtok */
--- 4918,4924 ----
         * wire-in knowledge about the default public privileges for different
         * kinds of objects.
         */
!       appendPQExpBuffer(sql, "REVOKE ALL ON %s %s FROM public;\n",
                                          type, name);
  
        /* Make a working copy of acls so we can use strtok */
***************
*** 4980,4986 ****
                                if (eqpos == tok)
                                {
                                        /* Empty left-hand side means "PUBLIC" */
!                                       appendPQExpBuffer(sql, "PUBLIC;\n");
                                }
                                else if (strncmp(tok, "group ", strlen("group ")) == 0)
                                        appendPQExpBuffer(sql, "GROUP %s;\n",
--- 4980,4986 ----
                                if (eqpos == tok)
                                {
                                        /* Empty left-hand side means "PUBLIC" */
!                                       appendPQExpBuffer(sql, "public;\n");
                                }
                                else if (strncmp(tok, "group ", strlen("group ")) == 0)
                                        appendPQExpBuffer(sql, "GROUP %s;\n",



---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]

Reply via email to