Re: psql: no schema info

Поиск
Список
Период
Сортировка
От chester c young
Тема Re: psql: no schema info
Дата
Msg-id 213749.31261.qm@web54304.mail.re2.yahoo.com
обсуждение исходный текст
Ответ на Re: psql: no schema info  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: psql: no schema info  (Richard Huxton <dev@archonet.com>)
Re: psql: no schema info  (Alvaro Herrera <alvherre@commandprompt.com>)
Список pgsql-sql
> > however, just got burnt big time on sequences!  need to qualify
> them as
> > well, eg
> >   col1 integer default nextval( 'schema1.seq1' )
> 
> Move to something newer than 8.0.x, and this is automatic (because
> nextval's argument is actually a regclass constant).
> 
>             regards, tom lane

using 8.2 and 8.3

here's (psychological) problem as I see it:

# set search_path=old_schema;
#
# create sequence new_schema.seq1;
#
# create table new_schema.table1(
#    col1 integer default nextval( 'seq1' )
# );

using old_schema.seq1, not new_schema.seq1

and imho to make matters more difficult to troubleshoot:

# \dt table1 -> does not show which schema for seq1


     ____________________________________________________________________________________
Be a better friend, newshound, and 
know-it-all with Yahoo! Mobile.  Try it now.  http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ


В списке pgsql-sql по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: psql: no schema info
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: psql: no schema info