Re: Beta time

Поиск
Список
Период
Сортировка
От Christopher Kings-Lynne
Тема Re: Beta time
Дата
Msg-id ECEHIKNFIMMECLEBJFIGOEPHCBAA.chriskl@familyhealth.com.au
обсуждение исходный текст
Ответ на Re: Beta time  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Beta time
Список pgsql-hackers
> 1. Should not "break" out of loop over indexes after detecting a
> matching non-primary-key index.  This allows detection of the NOTICE
> condition to distract you from detecting the ERROR condition on a
> later index.  I'd suggest issuing the NOTICE inside the loop, actually,
> and not breaking at all.  (See also #4)

OK.

> 2. What's with the "if (keyno > 0)"?  That breaks detection of
> everything on indexes on system columns, eg OID.  (Of course, the
> "rel_attrs[keyno - 1]" reference doesn't work for system columns,
> but sticking your head in the sand is no answer.)

This is code that I've borrowed from elsewhere.  I'll have a good look at it
tho.

> 3. pfree'ing iname at the bottom doesn't strike me as a good
> idea; isn't that possibly part of your input querytree?

Hmmm.  OK.  What about in the case where iname is null and I give it a
makeObjectName?

> 4. If you're going to be so pedantic as to issue a warning notice about
> a duplicate non-primary index, it'd be polite to give the name of that
> index.  Else how shall I know which index you think I should drop?

I'll improve the messages.  As for me being pedantic - that's a result of
what you specified as the best behaviour should be when I posted on the
list!

You may also want to look at the CONSTR_UNIQUE block that's already been
committed, as it may also have similar issues.  Any fixes I make to PRIMARY,
I will also fix in UNIQUE...

Cheers,

Chris



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Beta time
Следующее
От: Martín Marqués
Дата:
Сообщение: Re: Putting timestamps in PostgreSQL log