Using Tables from another database.

Поиск
Список
Период
Сортировка
Искать

Using Tables from another database.

От:
Rogério Baldini das Neves <baldini@infoquest.com.br>
Дата:
Hello,
 
I need to make a view like:
 
create view  view_test as select * from mydb.mytable;
 
and I get this error:
 
ERROR:  parser: parse error at or near "."
 
Whats the problem??
 
How can I solve this problem?
 
Thanks a lot,
 
Rogério Baldini
 
 

Re: Using Tables from another database.

От:
Bruno Wolff III <bruno@wolff.to>
Дата:
On Thu, Jul 25, 2002 at 10:36:09 -0300, Rogério Baldini das Neves  wrote:
> 
> How can I solve this problem?

The simplest answer is to pick a name that doesn't have a period in it.
If you are really trying to use schemas, you have to wait for 7.3.

Re: Using Tables from another database.

От:
"omid omoomi" <oomoomi@hotmail.com>
Дата:
hi,
You may simply write:

create view  view_test as select * from mytable;

But if the your table is in another database, then I am sorry. no way.

regards
Omid Omoomi


>From: Rog�rio Baldini das Neves 
>To: 
>Subject: [SQL] Using Tables from another database.
>Date: Thu, 25 Jul 2002 10:36:09 -0300
>
>Hello,
>
>I need to make a view like:
>
>create view  view_test as select * from mydb.mytable;
>
>and I get this error:
>
>ERROR:  parser: parse error at or near "."
>
>Whats the problem??
>
>How can I solve this problem?
>
>Thanks a lot,
>
>Rog�rio Baldini
>
>




_________________________________________________________________
Send and receive Hotmail on your mobile device: http://mobile.msn.com


Re: Using Tables from another database.

От:
Reinoud van Leeuwen <reinoud.v@n.leeuwen.net>
Дата:
On Thu, 25 Jul 2002 17:02:44 +0000 (UTC), baldini@infoquest.com.br
(Rogério Baldini das Neves) wrote:

>Hello,
>
>I need to make a view like:
>
>create view  view_test as select * from mydb.mytable;
>
>and I get this error:
>
>ERROR:  parser: parse error at or near "."
>
>Whats the problem??

This is possible in Sybase or Microsoft SQL server, not in Postgresql
(AFAIK)

-- 
__________________________________________________
"Nothing is as subjective as reality"
Reinoud van Leeuwen       reinoud.v@n.leeuwen.net
http://www.xs4all.nl/~reinoud

Re: Using Tables from another database.

От:
"D'Arcy J.M. Cain" <darcy@druid.net>
Дата:
* Reinoud van Leeuwen  [020726 08:05]:
> On Thu, 25 Jul 2002 17:02:44 +0000 (UTC), baldini@infoquest.com.br
> (Rogério Baldini das Neves) wrote:
> >create view  view_test as select * from mydb.mytable;
> 
> This is possible in Sybase or Microsoft SQL server, not in Postgresql
> (AFAIK)

Yet.  It's on the TODO list.

-- 
D'Arcy J.M. Cain    |  Democracy is three wolves
http://www.druid.net/darcy/                |  and a sheep voting on
+1 416 425 1212     (DoD#0082)    (eNTP)   |  what's for dinner.

FAQ