Re: BUG #5167: Alternative to USE of MSSQL

From: Devrim GÜNDÜZ <devrim(at)gunduz(dot)org>
To: forbiddenvk <for(dot)bid(dot)den(dot)vk(at)gmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #5167: Alternative to USE of MSSQL
Date: 2009-11-05 11:27:34
Message-ID: 1257420454.6861.33.camel@hp-laptop2.gunduz.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Thu, 2009-11-05 at 06:01 +0000, forbiddenvk wrote:
> Why couldn't create a alternative to USE command in MSSQL?, I think
> is
> necesary when we want execute a full script for create a database and
> tables
> in once.

(This is not a bug, but still...)

You can use psql's \c while scripting those kind of things.

Instead of using

USE dbname;

you can use this one:

\c dbname

and let psql read your script.
--
Devrim GÜNDÜZ, RHCE
Command Prompt - http://www.CommandPrompt.com
devrim~gunduz.org, devrim~PostgreSQL.org, devrim.gunduz~linux.org.tr
http://www.gunduz.org Twitter: http://twitter.com/devrimgunduz

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message tomas 2009-11-05 12:49:00 Re: BUG #5168: cannot login to server
Previous Message Pavel Stehule 2009-11-05 08:40:37 Re: BUG #5167: Alternative to USE of MSSQL