Thread: Enabling --log-update

Enabling --log-update

From
Dan Hrabarchuk
Date:
I need to track changes to my database while I'm doing a pg_dump.

I've found a reference to do this
http://www.arkeia.com/hotbackup/postgresql/ (see the second method).

It states that I need to put my database in the "mode --log-update"

I've tried to do this, but I keep getting an error saying that
--log-update needs an argument.

I can't find any documentation on this switch. Please help!

If I can't get this working my next alternative is to use either
http://gborg.postgresql.org/project/tablelog/projdisplay.php or
http://gborg.postgresql.org/project/audittrail/projdisplay.php

I need to have the database available while the dump is done.

Thanks is advance

Dan Hrabarchuk


Re: Enabling --log-update

From
Bruce Momjian
Date:
No idea what that is but I have never heard of those flags.  My guess is
that is a hacked version of PostgreSQL.

---------------------------------------------------------------------------

Dan Hrabarchuk wrote:
> I need to track changes to my database while I'm doing a pg_dump.
>
> I've found a reference to do this
> http://www.arkeia.com/hotbackup/postgresql/ (see the second method).
>
> It states that I need to put my database in the "mode --log-update"
>
> I've tried to do this, but I keep getting an error saying that
> --log-update needs an argument.
>
> I can't find any documentation on this switch. Please help!
>
> If I can't get this working my next alternative is to use either
> http://gborg.postgresql.org/project/tablelog/projdisplay.php or
> http://gborg.postgresql.org/project/audittrail/projdisplay.php
>
> I need to have the database available while the dump is done.
>
> Thanks is advance
>
> Dan Hrabarchuk
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 8: explain analyze is your friend
>

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

Migrating Data Between PG Tables

From
Mike Darretta
Date:
Does anyone have a suggestion on the best way to migrate data between
two slightly different tables? For example:

Table A
--------
id : integer
name : string
desc : string


Table B
--------
id : integer
name : string
date : date
summary : string

In this example, I would like to copy all the data from Table A into B,
using the desc column to populate the summary column.

Thanks,
Mike



Re: Migrating Data Between PG Tables

From
banghe
Date:
One sql statement can solve this:

sql> isnert into table_b (id, name, summary) select id, name, desc from
table_a;

Banghe

Mike Darretta wrote:

> Does anyone have a suggestion on the best way to migrate data between
> two slightly different tables? For example:
>
> Table A
> --------
> id : integer
> name : string
> desc : string
>
>
> Table B
> --------
> id : integer
> name : string
> date : date
> summary : string
>
> In this example, I would like to copy all the data from Table A into
> B, using the desc column to populate the summary column.
>
> Thanks,
> Mike
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>


Re: Migrating Data Between PG Tables

From
Mike Darretta
Date:
banghe wrote:

> One sql statement can solve this:
>
> sql> isnert into table_b (id, name, summary) select id, name, desc
> from table_a;
>
> Banghe
>
> Mike Darretta wrote:
>
>> Does anyone have a suggestion on the best way to migrate data between
>> two slightly different tables? For example:
>>
>> Table A
>> --------
>> id : integer
>> name : string
>> desc : string
>>
>>
>> Table B
>> --------
>> id : integer
>> name : string
>> date : date
>> summary : string
>>
>> In this example, I would like to copy all the data from Table A into
>> B, using the desc column to populate the summary column.
>>
>> Thanks,
>> Mike
>>
>>
>>
>> ---------------------------(end of broadcast)---------------------------
>> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>>
>
>
Thanks. I figured it was simple...


Re: Enabling --log-update

From
"Simon Riggs"
Date:
Whoever wrote the Arkeia pages was very confused. I've communicated with
them previously, but no one was home.

My understanding is that those are MySQL flag settings, not PostgreSQL.
Whatever, they certainly don't work with PostgreSQL.

"Tracking changes" while you do a dump is exactly what PITR does in v8.0,
now in beta.

Best Regards,

Simon Riggs

> -----Original Message-----
> From: pgsql-admin-owner@postgresql.org
> [mailto:pgsql-admin-owner@postgresql.org]On Behalf Of Bruce Momjian
> Sent: 05 October 2004 02:59
> To: Dan Hrabarchuk
> Cc: pgsql-admin@postgresql.org
> Subject: Re: [ADMIN] Enabling --log-update
>
>
>
> No idea what that is but I have never heard of those flags.  My guess is
> that is a hacked version of PostgreSQL.
>
> ------------------------------------------------------------------
> ---------
>
> Dan Hrabarchuk wrote:
> > I need to track changes to my database while I'm doing a pg_dump.
> >
> > I've found a reference to do this
> > http://www.arkeia.com/hotbackup/postgresql/ (see the second method).
> >
> > It states that I need to put my database in the "mode --log-update"
> >
> > I've tried to do this, but I keep getting an error saying that
> > --log-update needs an argument.
> >
> > I can't find any documentation on this switch. Please help!
> >
> > If I can't get this working my next alternative is to use either
> > http://gborg.postgresql.org/project/tablelog/projdisplay.php or
> > http://gborg.postgresql.org/project/audittrail/projdisplay.php
> >
> > I need to have the database available while the dump is done.
> >
> > Thanks is advance
> >
> > Dan Hrabarchuk
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 8: explain analyze is your friend
> >
>
> --
>   Bruce Momjian                        |  http://candle.pha.pa.us
>   pgman@candle.pha.pa.us               |  (610) 359-1001
>   +  If your life is a hard drive,     |  13 Roberts Road
>   +  Christ can be your backup.        |  Newtown Square,
> Pennsylvania 19073
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org