Re: psql: Make tab completion work for ANALYZE VERBOSE ...

From: Greg Sabino Mullane <greg(at)endpoint(dot)com>
To: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: psql: Make tab completion work for ANALYZE VERBOSE ...
Date: 2009-03-27 13:37:00
Message-ID: 49CCD67C.2000301@endpoint.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> I find that that particular rule is formatted differently than the
> others. It took me a while to figure out how it works.

Yeah, me too, but I was trying to keep my change inline with the local logic, so
to speak. +1 to making it more consistent.

> While we're at it, any idea what the logic behind this rule is:
>
>> else if ((pg_strcasecmp(prev_wd, "ANALYZE") == 0 &&
>> pg_strcasecmp(prev2_wd, "VERBOSE") == 0) ||
>> (pg_strcasecmp(prev_wd, "VERBOSE") == 0 &&
>> pg_strcasecmp(prev2_wd, "ANALYZE") == 0))
>> COMPLETE_WITH_SCHEMA_QUERY(Query_for_list_of_tables, NULL);
>
> ? The first part of that I understand, "ANALYZE VERBOSE", but "VERBOSE
> ANALYZE" isn't valid SQL.

I suspect this is to catch "VACUUM VERBOSE ANALYZE" (where VACUUM would be the
implicit prev3_wd)

--
Greg Sabino Mullane greg(at)endpoint(dot)com
End Point Corporation
PGP Key: 0x14964AC8

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2009-03-27 13:47:25 Re: SSL over Unix-domain sockets
Previous Message Simon Riggs 2009-03-27 13:09:24 Re: New trigger option of pg_standby