Skip site navigation (1) Skip section navigation (2)

Re: [GENERAL] Possible FAQs: single-quote and rename database

From: soundar rajan <psrajan(at)yahoo(dot)com>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, "Nathan L(dot) Cutler" <livingston(at)iol(dot)cz>
Cc: pgsql-general(at)postgreSQL(dot)org
Subject: Re: [GENERAL] Possible FAQs: single-quote and rename database
Date: 1999-12-27 14:47:51
Message-ID: 19991227144751.27754.qmail@web2105.mail.yahoo.com (view raw or flat)
Thread:
Lists: pgsql-general
Renaming the directory in the data directory doesn't
work either.



--- Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> wrote:
> > Hello:
> > 
> > I have two questions that might be FAQs (apologies
> in advance):
> > 
> > (1) Why does the parser choke on backslashed
> single-quote characters?  Or,
> > in other words, why doesn't this work:
> > 
> > testing=> \d bubba
> > Table    = bubba
> >
>
+--------------------------+----------------------------------+-------+
> > |          Field           |              Type    
>            | Length|
> >
>
+--------------------------+----------------------------------+-------+
> > | litbub                   | varchar()            
>            | 60    |
> >
>
+--------------------------+----------------------------------+-------+
> > testing=> insert '\'' into bubba;
> > ERROR:  parser: parse error at or near "'"
> 
> INSERT INTO bubba VALUES ('\'');
> 
> > 
> > (2) How does one rename a database?  Other than
> dump/destroydb/restore,
> > obviously.
> 
> I think you can modify pg_database with new name,
> stop postmaster,
> rename database directory, and restart.  Not sure,
> but that may work.
> 
> -- 
>   Bruce Momjian                        | 
> http://www.op.net/~candle
>   maillist(at)candle(dot)pha(dot)pa(dot)us            |  (610)
> 853-3000
>   +  If your life is a hard drive,     |  830 Blythe
> Avenue
>   +  Christ can be your backup.        |  Drexel
> Hill, Pennsylvania 19026
> 
> ************
> 


=====
Thanks.
Soundar.
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com

pgsql-general by date

Next:From: kaiqDate: 1999-12-27 16:06:47
Subject: Re: [GENERAL] Future of PostgreSQL
Previous:From: Nikolay MijaylovDate: 1999-12-27 14:14:25
Subject: Fw: [GENERAL] Future of PostgreSQL

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group