Thread: cannot dump 7.3.3 table using pg_dump of 7.4dev

cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Date:
Hi i want to try out 7.4dev by loading my entire 7.3.3 database ~ [ 6 GB ]
but in a particular table i get below:

$ /usr/local/pgsql7.4/bin/pg_dump   -p 5432 -t intranet_company
tradein_clients > out.sqlpg_dump: invalid adnum value 31 for table "intranet_company"


regds
mallah.


-----------------------------------------
Over 1,00,000 exporters are waiting for your order! Click below to get
in touch with leading Indian exporters listed in the premier
trade directory Exporters Yellow Pages.
http://www.trade-india.com/dyn/gdh/eyp/



Re: cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Tom Lane
Date:
<mallah@trade-india.com> writes:
> Hi i want to try out 7.4dev by loading my entire 7.3.3 database ~ [ 6 GB ]
> but in a particular table i get below:

> $ /usr/local/pgsql7.4/bin/pg_dump   -p 5432 -t intranet_company
> tradein_clients > out.sqlpg_dump: invalid adnum value 31 for table "intranet_company"

Does your 7.3 pg_dump work?  It doesn't look like that area of pg_dump
has changed since 7.3 ...

            regards, tom lane

Re: cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Date:
Yes,
/usr/local/pgsql/bin/pg_dump  -p 5432   -t intranet_company
tradein_clients > out.sql[postgres@ns3 postgres]$ /usr/local/pgsql/bin/pg_dump --version
pg_dump (PostgreSQL) 7.3.3
[postgres@ns3 postgres]$



Regds
Mallah.


> <mallah@trade-india.com> writes:
>> Hi i want to try out 7.4dev by loading my entire 7.3.3 database ~ [ 6
>> GB ] but in a particular table i get below:
>
>> $ /usr/local/pgsql7.4/bin/pg_dump   -p 5432 -t intranet_company
>> tradein_clients > out.sqlpg_dump: invalid adnum value 31 for table
>> "intranet_company"
>
> Does your 7.3 pg_dump work?  It doesn't look like that area of pg_dump
> has changed since 7.3 ...
>
>             regards, tom lane



-----------------------------------------
Over 1,00,000 exporters are waiting for your order! Click below to get
in touch with leading Indian exporters listed in the premier
trade directory Exporters Yellow Pages.
http://www.trade-india.com/dyn/gdh/eyp/



Re: cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Tom Lane
Date:
<mallah@trade-india.com> writes:
>> Does your 7.3 pg_dump work?  It doesn't look like that area of pg_dump
>> has changed since 7.3 ...

> Yes,

Bizarre.  Would you send the results of
select * from pg_attribute where attrelid = 'intranet_company'::regclass;
select * from pg_attrdef where adrelid = 'intranet_company'::regclass;

            regards, tom lane

Re: cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Date:
i have pasted the results using pg 7.4dev psql
but the formatting are lost , lemme know how i
can help.

regds
mallah.


> <mallah@trade-india.com> writes:
>>> Does your 7.3 pg_dump work?  It doesn't look like that area of
>>> pg_dump has changed since 7.3 ...
>
>> Yes,
>
> Bizarre.  Would you send the results of
> select * from pg_attribute where attrelid =
> 'intranet_company'::regclass;

 attrelid |            attname            | atttypid | attstattarget |
 attlen | attnum | attndims | attcacheoff | atttypmod | attbyval |
 attstorage | attisset | attalign | attnotnull | atthasdef | attisdropped
 | attislocal |
attinhcount----------+-------------------------------+----------+---------------+--------+--------+----------+-------------+-----------+----------+------------+----------+----------+------------+-----------+--------------+------------+-------------
14657817| tableoid                      |       26 |             0 |     
  4 |     -7 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | cmax                          |       29 |             0 |
  4 |     -6 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | xmax                          |       28 |             0 |
  4 |     -5 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | cmin                          |       29 |             0 |
  4 |     -4 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | xmin                          |       28 |             0 |
  4 |     -3 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | oid                           |       26 |             0 |
  4 |     -2 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | ctid                          |       27 |             0 |
  6 |     -1 |        0 |          -1 |        -1 | f        | p
 | f        | i        | t          | f         | f            | t
  |           0 14657817 | companyid                     |       23 |            -1 |
  4 |      1 |        0 |          -1 |        -1 | t        | p
 | f        | i        | t          | t         | f            | t
  |           0 14657817 | user_id                       |       23 |            -1 |
  4 |      2 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | branch_id                     |     1043 |            -1 |
 -1 |      3 |        0 |          -1 |        74 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | type                          |     1043 |            -1 |
 -1 |      4 |        0 |          -1 |        14 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | ed                            |       23 |            -1 |
  4 |      5 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | edate                         |     1082 |            -1 |
  4 |      6 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | company                       |     1043 |            -1 |
 -1 |      7 |        0 |          -1 |       204 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | adsize                        |     1043 |            -1 |
 -1 |      8 |        0 |          -1 |        24 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | contract_date                 |     1082 |            -1 |
  4 |      9 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | ........pg.dropped.10........ |        0 |             0 |
 -1 |     10 |        0 |          -1 |        24 | f        | x
 | f        | i        | f          | f         | t            | t
  |           0 14657817 | cvalue                        |       23 |            -1 |
  4 |     11 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | discount                      |     1043 |            -1 |
 -1 |     12 |        0 |          -1 |        14 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | part_payment                  |       16 |            -1 |
  1 |     13 |        0 |          -1 |        -1 | t        | p
 | f        | c        | f          | t         | f            | t
  |           0 14657817 | barter                        |       16 |            -1 |
  1 |     14 |        0 |          -1 |        -1 | t        | p
 | f        | c        | f          | t         | f            | t
  |           0 14657817 | stat                          |       16 |            -1 |
  1 |     15 |        0 |          -1 |        -1 | t        | p
 | f        | c        | f          | t         | f            | t
  |           0 14657817 | cno                           |     1043 |            -1 |
 -1 |     16 |        0 |          -1 |        14 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | balance                       |       23 |            -1 |
  4 |     17 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | gdate                         |     1114 |            -1 |
  8 |     18 |        0 |          -1 |        -1 | f        | p
 | f        | d        | f          | t         | f            | t
  |           0 14657817 | category_id                   |       23 |            -1 |
  4 |     19 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | cperson                       |     1043 |            -1 |
 -1 |     20 |        0 |          -1 |        34 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | expected                      |     1043 |            -1 |
 -1 |     21 |        0 |          -1 |        34 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | matter                        |       16 |            -1 |
  1 |     22 |        0 |          -1 |        -1 | t        | p
 | f        | c        | f          | t         | f            | t
  |           0 14657817 | ........pg.dropped.23........ |     1043 |             0 |
 -1 |     23 |        0 |          -1 |        34 | f        | x
 | f        | i        | f          | f         | t            | t
  |           0 14657817 | letter_date                   |     1082 |            -1 |
  4 |     24 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | ........pg.dropped.25........ |       16 |             0 |
  1 |     25 |        0 |          -1 |        -1 | t        | p
 | f        | c        | f          | f         | t            | t
  |           0 14657817 | email                         |     1043 |            -1 |
 -1 |     26 |        0 |          -1 |        64 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | letter_status                 |     1043 |            -1 |
 -1 |     27 |        0 |          -1 |         5 | f        | x
 | f        | i        | f          | t         | f            | t
  |           0 14657817 | category_name                 |       25 |            -1 |
 -1 |     28 |        0 |          -1 |        -1 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | title                         |     1043 |            -1 |
 -1 |     29 |        0 |          -1 |        14 | f        | x
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | contract_no                   |       23 |            -1 |
  4 |     30 |        0 |          -1 |        -1 | t        | p
 | f        | i        | f          | f         | f            | t
  |           0 14657817 | renewal                       |       16 |            -1 |
  1 |     31 |        0 |          -1 |        -1 | t        | p
 | f        | c        | f          | t         | f            | t
  |           0(38 rows)

tradein_clients=>














select * from pg_attrdef where adrelid =
> 'intranet_company'::regclass;


tradein_clients=> select * from pg_attrdef where adrelid =
'intranet_company'::regclass; adrelid  | adnum |

                                        adbin

                                                                  |

adsrc----------+-------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------
14657817|     1 | { EXPR :typeOid 20  :opType func :oper { FUNC :funcid 
 1574 :funcresulttype 20 :funcretset false :funcformat 0 } :args ({ CONST
 :consttype 25 :constlen -1 :constbyval false :constisnull false
 :constvalue  36 [ 36 0 0 0 34 105 110 116 114 97 110 101 116 95 99 111
 109 112 97 110 121 95 99 111 109 112 97 110 121 105 100 95 115 101 113 34
 ] })} | nextval('"intranet_company_companyid_seq"'::text) 14657817 |    13 | { CONST :consttype 705 :constlen -1
:constbyvalfalse 
 :constisnull false :constvalue  5 [ 5 0 0 0 102 ] }


                                                                   | 'f' 14657817 |    14 | { CONST :consttype 705
:constlen-1 :constbyval false 
 :constisnull false :constvalue  5 [ 5 0 0 0 102 ] }


                                                                   | 'f' 14657817 |    15 | { CONST :consttype 705
:constlen-1 :constbyval false 
 :constisnull false :constvalue  5 [ 5 0 0 0 102 ] }


                                                                   | 'f' 14657817 |    18 | { EXPR :typeOid 1184
:opTypefunc :oper { FUNC 
 :funcid 1299 :funcresulttype 1184 :funcretset false :funcformat 0 } :args
 <>}

                                                                         |
 now() 14657817 |    22 | { CONST :consttype 705 :constlen -1 :constbyval false
 :constisnull false :constvalue  5 [ 5 0 0 0 102 ] }


                                                                   | 'f' 14657817 |    27 | { CONST :consttype 705
:constlen-1 :constbyval false 
 :constisnull false :constvalue  5 [ 5 0 0 0 110 ] }


                                                                   | 'n' 14657817 |    31 | { CONST :consttype 705
:constlen-1 :constbyval false 
 :constisnull false :constvalue  5 [ 5 0 0 0 102 ] }


                                                                   | 'f'(8 rows)

tradein_clients=>






>
>             regards, tom lane
>
> ---------------------------(end of
> broadcast)--------------------------- TIP 5: Have you checked our
> extensive FAQ?
>
>               http://www.postgresql.org/docs/faqs/FAQ.html



-----------------------------------------
Over 1,00,000 exporters are waiting for your order! Click below to get
in touch with leading Indian exporters listed in the premier
trade directory Exporters Yellow Pages.
http://www.trade-india.com/dyn/gdh/eyp/



Re: cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Tom Lane
Date:
<mallah@trade-india.com> writes:
>   |           0 14657817 | ........pg.dropped.10........ |        0 |             0 |
>  -1 |     10 |        0 |          -1 |        24 | f        | x
>  | f        | i        | f          | f         | t            | t

Mph.  I see the problem --- looks like someone decided it would be a
bright idea to inner-join pg_attribute to pg_type while picking up the
column data in getTableAttrs.  Unfortunately this can fail for deleted
columns.  Will have a fix shortly.

            regards, tom lane

Re: cannot dump 7.3.3 table using pg_dump of 7.4dev

From
Date:
thanks.

regds
mallah.

> <mallah@trade-india.com> writes:
>>   |           0 14657817 | ........pg.dropped.10........ |        0 |
>>              0 |
>>  -1 |     10 |        0 |          -1 |        24 | f        | x
>>     | f        | i        | f          | f         | t            | t
>>
>
> Mph.  I see the problem --- looks like someone decided it would be a
> bright idea to inner-join pg_attribute to pg_type while picking up the
> column data in getTableAttrs.  Unfortunately this can fail for deleted
> columns.  Will have a fix shortly.
>
>             regards, tom lane



-----------------------------------------
Over 1,00,000 exporters are waiting for your order! Click below to get
in touch with leading Indian exporters listed in the premier
trade directory Exporters Yellow Pages.
http://www.trade-india.com/dyn/gdh/eyp/