Re: Correct Insert SQL syntax? - Mailing list pgsql-sql

From Lennin Caro
Subject Re: Correct Insert SQL syntax?
Date
Msg-id 446001.91912.qm@web59508.mail.ac4.yahoo.com
Whole thread Raw
In response to Correct Insert SQL syntax?  ("Ruben Gouveia" <rubes7202@gmail.com>)
Responses Re: Correct Insert SQL syntax?
List pgsql-sql


--- On Thu, 9/4/08, Ruben Gouveia <rubes7202@gmail.com> wrote:

> From: Ruben Gouveia <rubes7202@gmail.com>
> Subject: [SQL] Correct Insert SQL syntax?
> To: "pgsql-sql" <pgsql-sql@postgresql.org>
> Date: Thursday, September 4, 2008, 10:16 PM
> Will this syntax work:
> 
> fcn_stats are all in the same schema
> 
> CREATE OR REPLACE FUNCTION insert_stats(p_date date)
> RETURNS void AS $$
> 
>           BEGIN
>                     insert into stats (
>                             date,
>                             stats1,
>                             stats2
>                     ) (select
>                           p_date,
>                          
> fcn_stats1(p_date,'basic'),
>                          
> fcn_stats2(p_date,'basic',0)
>                           from dual
>                      );
> END;
> $$ LANGUAGE 'plpgsql';


Dual is a table create for you or is the generic table of oracle?


     



pgsql-sql by date:

Previous
From: "Bart Degryse"
Date:
Subject: Re: Correct Insert SQL syntax?
Next
From: "Scott Marlowe"
Date:
Subject: Re: Correct Insert SQL syntax?