dbTalk Databases Forums  

[BUGS] psql client 7.4RC1 completion bug

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss [BUGS] psql client 7.4RC1 completion bug in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Oliver Siegmar
 
Posts: n/a

Default [BUGS] psql client 7.4RC1 completion bug - 11-08-2003 , 02:30 PM






================================================== ==========================
POSTGRESQL BUG REPORT TEMPLATE
================================================== ==========================


Your name : Oliver Siegmar
Your email address : oliver.siegmar (AT) xams (DOT) org


Please enter a FULL description of your problem:
------------------------------------------------

psql -U username template1
template1=# alter database databasename <TAB><TAB>
RESET SET
template1=# \h alter database
Command: ALTER DATABASE
Description: change a database
Syntax:
ALTER DATABASE name SET parameter { TO | = } { value | DEFAULT }
ALTER DATABASE name RESET parameter

ALTER DATABASE name RENAME TO newname


....the psql Tab completion doesn't show the rename command.


---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

Reply With Quote
  #2  
Old   
Bruce Momjian
 
Posts: n/a

Default Re: [BUGS] psql client 7.4RC1 completion bug - 11-08-2003 , 02:56 PM






--ELM1068324874-1164-2_
Content-Transfer-Encoding: 7bit
Content-Type: text/plain; charset=US-ASCII

Oliver Siegmar wrote:
Quote:
================================================== ==========================
POSTGRESQL BUG REPORT TEMPLATE
================================================== ==========================


Your name : Oliver Siegmar
Your email address : oliver.siegmar (AT) xams (DOT) org


Please enter a FULL description of your problem:
------------------------------------------------

psql -U username template1
template1=# alter database databasename <TAB><TAB
RESET SET
template1=# \h alter database
Command: ALTER DATABASE
Description: change a database
Syntax:
ALTER DATABASE name SET parameter { TO | = } { value | DEFAULT }
ALTER DATABASE name RESET parameter

ALTER DATABASE name RENAME TO newname


...the psql Tab completion doesn't show the rename command.
OK, found the bug. With the attached patch, it now show:

test=> ALTER DATABASE test
RENAME TO RESET SET

This will appear in 7.4 final.

--
Bruce Momjian | http://candle.pha.pa.us
pgman (AT) candle (DOT) 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

--ELM1068324874-1164-2_
Content-Transfer-Encoding: 7bit
Content-Type: text/plain
Content-Disposition: inline; filename="/bjm/diff"

Index: src/bin/psql/tab-complete.c
================================================== =================
RCS file: /cvsroot/pgsql-server/src/bin/psql/tab-complete.c,v
retrieving revision 1.92
diff -c -c -r1.92 tab-complete.c
*** src/bin/psql/tab-complete.c 6 Nov 2003 22:08:15 -0000 1.92
--- src/bin/psql/tab-complete.c 8 Nov 2003 20:51:48 -0000
***************
*** 645,651 ****
strcasecmp(prev2_wd, "DATABASE") == 0)
{
static const char *const list_ALTERDATABASE[] =
! {"RESET", "SET", NULL};

COMPLETE_WITH_LIST(list_ALTERDATABASE);
}
--- 645,651 ----
strcasecmp(prev2_wd, "DATABASE") == 0)
{
static const char *const list_ALTERDATABASE[] =
! {"RESET", "SET", "RENAME TO", NULL};

COMPLETE_WITH_LIST(list_ALTERDATABASE);
}

--ELM1068324874-1164-2_
Content-Type: text/plain
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
MIME-Version: 1.0


---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to majordomo (AT) postgresql (DOT) org)

--ELM1068324874-1164-2_--


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.