David Dunwoody wrote:
OK, just reproduced with 8.2.6 compiled from source on Ubuntu 7.10
(all updates applied as a couple of hours ago).
Steps to reproduce. Forgive any typos, this isn't all from
bash_history, but was done on a machine that never had postgresql on
it before (specifically, my laptop).
Command output is shown between ... characters.
** Basic install and clean DB setup:
wget http://mirror/postgresql-8.2.6.tar.gz
tar zxvf postgres-8.2.6.tar.gz
cd postgresql-8.2.6
./configure --prefix=/opt/postgres
make
sudo make install
sudo lndir /opt/postgres/bin /usr/local/bin
sudo mkdir /opt/postgres/data
sudo chown postgres /opt/postgres/data
sudo adduser postgres
sudo su - postgres
initdb -D /opt/postgres/data
postgres -D /opt/postgres/data > logfile 2>&1 &
createdb test
psql test
** Create test tables:
create table a ( col1 date, col2 date );
create table b ( col1 date, col2 date );
create table c ( col1 date, col2 date );
exit psql
** Sanity check psql:
pg_dump -v test > /dev/null
...
pg_dump: creating TABLE a
pg_dump: creating TABLE b
pg_dump: creating TABLE c
...
As expected
** Check --exclude-table option:
pg_dump -v --exclude-table=b test > /dev/null
...
pg_dump: creating TABLE a
pg_dump: creating TABLE c
...
As expected
** Check -T option:
pg_dump -v -T=b test > /dev/null
...
pg_dump: creating TABLE a
pg_dump: creating TABLE b
pg_dump: creating TABLE c
...
Silently ignores -T
I hope I'm an idiot, but that looks like a bug according to pg_dump
--help which says:
...
-T, --exclude-table=TABLE do NOT dump the named table(s)
...
Hope that helps you reproduce it.
Cheers,
David
On 30/01/2008, *Tom Lane* <[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]>> wrote:
Zdenek Kotala <[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]>> writes:
> David Dunwoody wrote:
>> When running pg_dump, the -T option for table exclusion is
ignored, but
>> --exclude-table does work.
> It works for me. Can you recheck it again?
Works for me too, on Fedora 8. But could you give a complete example?
Maybe there's some other contributing factor in the particular case
you're trying.
regards, tom lane
Hola, hasta donde veo lo que esta de mas es el igual (=) -T=b debe decir
-T b
Saludos Fernando
---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match