Re: Creating Views

From: Kenneth C Stahl <>
Date: Mon, 23 Aug 1999 08:15:32 -0400
Message-ID: <>

Kenny wrote:

> Hey all,
> Two part question:
> First, I am trying to create a view that joins two tables, both tables
> having the same primary key. After creating the view, if I then insert,
> update, or delete a record from that view, will it affect both tables?
> Second, Can someone tell me the syntax of joining two tables in the
> create view statement.
> I know its something like:
> create view combo as select cust_id, first_name, last_name from customer
> ( here is the part where I want to also select cust_id, first_name,
> last_name from another table called preferences)

You cannot insert into a view that is defined with a join.

The syntax for creating a view containing a join is exactly the same syntax as entering a sql statement which contains a join except that it would be preceded with:

create or replace view myview as
select ......

Ken Received on Mon Aug 23 1999 - 14:15:32 CEST

Original text of this message