How to RENAME an INFORMIX database
Posted in 2007
A user asked how to rename an Informix database. Replies pointed to the SQL statement RENAME DATABASE olddb TO newdb (supported from certain versions; IDS 10 documentation link given). One poster suggested you must run it while connected to sysmaster, e.g. echo "rename database mydb to newdb;" | dbaccess sysmaster, but another clarified that you only need a connection to the instance, not to any particular database — just not to the database being renamed, or the rename will fail. The original poster thanked the group; problem resolved.
Auto-generated by DrWatson from the posts below — may be imperfect; read the full thread.
Topics: General Discussion
Hi All, Can anyone help me in renaming my database. Let my database name is "mydb"? Thanks in advance. Regards, Navaid Arif
Depends on the version but here is the basic syntax if it is supported; RENAME DATABASE "xyz" TO "mydb"; Documentation for V10; <http://publib.boulder.ibm.com/infocenter/idshelp/v10/index.jsp?topic=/com.ibm.s qls.doc/sqls621.htm> Eric B. Rowell On Dec 6, 2007 8:24 AM, Navaid Arif <navaid.arif@access.net.pk> wrote: > Hi All, > > Can anyone help me in renaming my database. Let my database name is "mydb"? > > Thanks in advance. > > Regards, > Navaid Arif > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. > >
On 06/12/2007, Navaid Arif <navaid.arif@access.net.pk> wrote: > Hi All, > > Can anyone help me in renaming my database. Let my database name is "mydb"? > > Thanks in advance. > > Regards, > Navaid Arif > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. > > Reply elsewhere !!
You can run the following sql. rename database mydb to newdatabasename ; Sushil... > To: ids@iiug.org> From: smiley73@googlemail.com> Subject: Re: How to RENAME an INFORMIX database [10625]> Date: Thu, 6 Dec 2007 08:34:09 -0500> > On 06/12/2007, Navaid Arif <navaid.arif@access.net.pk> wrote: > > Hi All, > > > > Can anyone help me in renaming my database. Let my database name is "mydb"? > > > > Thanks in advance. > > > > Regards, > > Navaid Arif > > > > > > > ******************************************************************************* > > Forum Note: Use "Reply" to post a response in the discussion forum. > > > > > Reply elsewhere !! > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. > _________________________________________________________________ Connect and share in new ways with Windows Live. http://www.windowslive.com/connect.html?ocid=TXT_TAGLM_Wave2_newways_112007
Don't you have to be connected to the sysmaster db to rename your own
db?
eg: from command line:
echo "rename database mydb to newdatabasename;" | dbaccess sysmaster
Bob Roussey
Unix / Informix Administration
Spirit Airlines
Robert.Roussey@SpiritAir.com
-----Original Message-----
From: ids-bounces@iiug.org [mailto:ids-bounces@iiug.org] On Behalf Of
Sushil Shirodkar
Sent: Thursday, December 06, 2007 9:33 AM
To: ids@iiug.org
Subject: RE: How to RENAME an INFORMIX database [10626]
You can run the following sql.
rename database mydb to newdatabasename ;
Sushil...
> To: ids@iiug.org> From: smiley73@googlemail.com> Subject: Re: How to
RENAME
an INFORMIX database [10625]> Date: Thu, 6 Dec 2007 08:34:09 -0500> > On
06/12/2007, Navaid Arif <navaid.arif@access.net.pk> wrote: > > Hi All, >
> > >
Can anyone help me in renaming my database. Let my database name is
"mydb"? >
> > > Thanks in advance. > > > > Regards, > > Navaid Arif > > > > > > >
************************************************************************
*******
> > Forum Note: Use "Reply" to post a response in the discussion forum.
> > >
> > Reply elsewhere !! > > >
************************************************************************
*******
> Forum Note: Use "Reply" to post a response in the discussion forum. >
_________________________________________________________________
Connect and share in new ways with Windows Live.
http://www.windowslive.com/connect.html?ocid=TXT_TAGLM_Wave2_newways_112
007
************************************************************************
*******
Forum Note: Use "Reply" to post a response in the discussion forum.
You don't need to connect to sysmaster (or any database) -- you need to
connect to the instance, then rename the database -- just make sure you don't
connect to the same database or you will fail to rename.
----- Original Message ----
From: Robert Roussey(IT) <Robert.Roussey@SpiritAir.com>
To: ids@iiug.org
Sent: Thursday, December 6, 2007 10:07:21 AM
Subject: RE: How to RENAME an INFORMIX database [10628]
Don't you have to be connected to the sysmaster db to rename your own
db?
eg: from command line:
echo "rename database mydb to newdatabasename;" | dbaccess sysmaster
Bob Roussey
Unix / Informix Administration
Spirit Airlines
Robert.Roussey@SpiritAir.com
-----Original Message-----
From: ids-bounces@iiug.org [mailto:ids-bounces@iiug.org] On Behalf Of
Sushil Shirodkar
Sent: Thursday, December 06, 2007 9:33 AM
To: ids@iiug.org
Subject: RE: How to RENAME an INFORMIX database [10626]
You can run the following sql.
rename database mydb to newdatabasename ;
Sushil...
> To: ids@iiug.org> From: smiley73@googlemail.com> Subject: Re: How to
RENAME
an INFORMIX database [10625]> Date: Thu, 6 Dec 2007 08:34:09 -0500> > On
06/12/2007, Navaid Arif <navaid.arif@access.net.pk> wrote: > > Hi All, >
> > >
Can anyone help me in renaming my database. Let my database name is
"mydb"? >
> > > Thanks in advance. > > > > Regards, > > Navaid Arif > > > > > > >
************************************************************************
*******
> > Forum Note: Use "Reply" to post a response in the discussion forum.
> > >
> > Reply elsewhere !! > > >
************************************************************************
*******
> Forum Note: Use "Reply" to post a response in the discussion forum. >
_________________________________________________________________
Connect and share in new ways with Windows Live.
http://www.windowslive.com/connect.html?ocid=TXT_TAGLM_Wave2_newways_112
007
************************************************************************
*******
Forum Note: Use "Reply" to post a response in the discussion forum.
*******************************************************************************
Forum Note: Use "Reply" to post a response in the discussion forum.
________________________________________________________________________________
____
Never miss a thing. Make Yahoo your home page.
http://www.yahoo.com/r/hs
Thanks Sushil. Regards, Navaid Arif . ----- Original Message ----- From: "Sushil Shirodkar" <sushilps@hotmail.com> To: <ids@iiug.org> Sent: Thursday, December 06, 2007 7:33 PM Subject: RE: How to RENAME an INFORMIX database [10626] > You can run the following sql. > > rename database mydb to newdatabasename ; > Sushil... >> To: ids@iiug.org> From: smiley73@googlemail.com> Subject: Re: How to >> RENAME > an INFORMIX database [10625]> Date: Thu, 6 Dec 2007 08:34:09 -0500> > On > 06/12/2007, Navaid Arif <navaid.arif@access.net.pk> wrote: > > Hi All, > > > > > > Can anyone help me in renaming my database. Let my database name is > "mydb"? > >> > > Thanks in advance. > > > > Regards, > > Navaid Arif > > > > > > > > ******************************************************************************* >> > Forum Note: Use "Reply" to post a response in the discussion forum. > > >> > > >> > Reply elsewhere !! > > > > ******************************************************************************* >> Forum Note: Use "Reply" to post a response in the discussion forum. > > _________________________________________________________________ > Connect and share in new ways with Windows Live. > http://www.windowslive.com/connect.html?ocid=TXT_TAGLM_Wave2_newways_112007 > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. >
Thanks Eric. Regards, Navaid Arif. ----- Original Message ----- From: "Eric Rowell" <erowell@gmail.com> To: <ids@iiug.org> Sent: Thursday, December 06, 2007 6:30 PM Subject: Re: How to RENAME an INFORMIX database [10624] > Depends on the version but here is the basic syntax if it is supported; > > RENAME DATABASE "xyz" TO "mydb"; > > Documentation for V10; > > <http://publib.boulder.ibm.com/infocenter/idshelp/v10/index.jsp?topic=/com.ibm.s qls.doc/sqls621.htm> > > Eric B. Rowell > > On Dec 6, 2007 8:24 AM, Navaid Arif <navaid.arif@access.net.pk> wrote: >> Hi All, >> >> Can anyone help me in renaming my database. Let my database name is >> "mydb"? >> >> Thanks in advance. >> >> Regards, >> Navaid Arif >> >> >> > ******************************************************************************* >> Forum Note: Use "Reply" to post a response in the discussion forum. >> >> > > > ******************************************************************************* > Forum Note: Use "Reply" to post a response in the discussion forum. >
Thanks a lot everyone.
Regards,
Navaid Arif.
----- Original Message -----
From: "Kern Doe" <kern_doe@yahoo.com>
To: <ids@iiug.org>
Sent: Thursday, December 06, 2007 8:12 PM
Subject: Re: How to RENAME an INFORMIX database [10629]
> You don't need to connect to sysmaster (or any database) -- you need to
> connect to the instance, then rename the database -- just make sure you
> don't
> connect to the same database or you will fail to rename.
>
> ----- Original Message ----
> From: Robert Roussey(IT) <Robert.Roussey@SpiritAir.com>
> To: ids@iiug.org
> Sent: Thursday, December 6, 2007 10:07:21 AM
> Subject: RE: How to RENAME an INFORMIX database [10628]
>
> Don't you have to be connected to the sysmaster db to rename your own
> db?
>
> eg: from command line:
>
> echo "rename database mydb to newdatabasename;" | dbaccess sysmaster
>
> Bob Roussey
> Unix / Informix Administration
> Spirit Airlines
> Robert.Roussey@SpiritAir.com
>
> -----Original Message-----
> From: ids-bounces@iiug.org [mailto:ids-bounces@iiug.org] On Behalf Of
> Sushil Shirodkar
> Sent: Thursday, December 06, 2007 9:33 AM
> To: ids@iiug.org
> Subject: RE: How to RENAME an INFORMIX database [10626]
>
> You can run the following sql.
>
> rename database mydb to newdatabasename ;
> Sushil...
>> To: ids@iiug.org> From: smiley73@googlemail.com> Subject: Re: How to
> RENAME
> an INFORMIX database [10625]> Date: Thu, 6 Dec 2007 08:34:09 -0500> > On
>
> 06/12/2007, Navaid Arif <navaid.arif@access.net.pk> wrote: > > Hi All, >
>> > >
> Can anyone help me in renaming my database. Let my database name is
> "mydb"? >
>> > > Thanks in advance. > > > > Regards, > > Navaid Arif > > > > > > >
> ************************************************************************
> *******
>> > Forum Note: Use "Reply" to post a response in the discussion forum.
>> > >
>> > Reply elsewhere !! > > >
> ************************************************************************
> *******
>> Forum Note: Use "Reply" to post a response in the discussion forum. >
> _________________________________________________________________
> Connect and share in new ways with Windows Live.
> http://www.windowslive.com/connect.html?ocid=TXT_TAGLM_Wave2_newways_112
> 007
>
> ************************************************************************
> *******
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>
>
>
________________________________________________________________________________
____
> Never miss a thing. Make Yahoo your home page.
> http://www.yahoo.com/r/hs
>
>
>
*******************************************************************************
> Forum Note: Use "Reply" to post a response in the discussion forum.
>