Thread

  1. pg_dump doesn't handle CREATE FUNCTIONs well

    PostgreSQL Bugs List <pgsql-bugs@postgresql.org> — 2001-07-25T02:07:05Z

    Rainer Mager (rmager@vgkk.com) reports a bug with a severity of 2
    The lower the number the more severe it is.
    
    Short Description
    pg_dump doesn't handle CREATE FUNCTIONs well
    
    Long Description
    We have a table (table_A) that has a constraint on it that uses a custom function (func_B), which references a different table (table_C). When we do a pg_dump all of the table and function definitions are created correctly but in the wrong order.
    
    The dump has the items in this order: table_C, table_A, func_B
    The problem is that the creation of table_A requires the existence of func_B. Therefore the dump should have dumped things in this order: table_C, func_B, table_A.
    
    This is reasonably easy to fix by hand because we only have one such situation and the trail is easy to trace. A more complicated situation could be a pain to fix by hand.
    
    Sample Code
    
    
    No file was uploaded with this report
    
    
    
  2. Re: pg_dump doesn't handle CREATE FUNCTIONs well

    Tom Lane <tgl@sss.pgh.pa.us> — 2001-07-25T06:26:42Z

    pgsql-bugs@postgresql.org writes:
    > pg_dump doesn't handle CREATE FUNCTIONs well
    
    Any particular version to mention with that?
    
    AFAIK this is fixed in the current release (7.1.2)
    
    			regards, tom lane
    
    
  3. RE: pg_dump doesn't handle CREATE FUNCTIONs well

    Rainer Mager <rmager@vgkk.com> — 2001-07-25T06:34:16Z

    I saw the problem in 2 different (but mirrored and therefore identical)
    7.1.2 databases. The data was created in the db before 7.1.2 but it has
    since been upgraded and the dump was via 7.1.2. Was the bug in the dump code
    or did it have to do with db creation?
    
    Thanks,
    
    --Rainer
    
    
    > -----Original Message-----
    > From: Tom Lane [mailto:tgl@sss.pgh.pa.us]
    > Sent: Wednesday, July 25, 2001 3:27 PM
    > To: rmager@vgkk.com; pgsql-bugs@postgresql.org
    > Subject: Re: [BUGS] pg_dump doesn't handle CREATE FUNCTIONs well
    >
    >
    > pgsql-bugs@postgresql.org writes:
    > > pg_dump doesn't handle CREATE FUNCTIONs well
    >
    > Any particular version to mention with that?
    >
    > AFAIK this is fixed in the current release (7.1.2)
    >
    > 			regards, tom lane
    
    
    
  4. Re: pg_dump doesn't handle CREATE FUNCTIONs well

    Tom Lane <tgl@sss.pgh.pa.us> — 2001-07-25T07:23:41Z

    "Rainer Mager" <rmager@vgkk.com> writes:
    > ... the dump was via 7.1.2.
    
    Oh?  Then it'd be a still-extant pg_dump bug.  May we see a complete,
    reproducible example?
    
    			regards, tom lane