O Markus Schaber έγραψε στις Feb 2, 2006 :

> Hi, Daniel,
> 
> Daniel Caune wrote:
> 
> > I'm not sure to understand.  Why calling a function from a script is 
> > different from executing a series of SQL commands?  I mean, I can run a 
> > script defined as follows:
> > 
> > SELECT myjob();
> > 
> > where myjob is a stored procedure such as:
> > 
> > CREATE OR REPLACE FUNCTION myjob()
> >   RETURNS void
> > AS $$
> >   <a-lot-of-complex-stuff-here>
> > END;
> > $$ LANGUAGE PLPGSQL;
> > 
> > Does that make sense?
> 
> It does make sense if myjob() does more than just execute a bunch of
> statements, e. G. it contains if(), loops or something else.
> 
> PLPGSQL is turing complete, plain SQL is not.

Hmmmm is SQL equally powerful as a pushdown automaton then???

Just kidding!

> 
> Markus
> 

-- 
-Achilleus


---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to [EMAIL PROTECTED] so that your
       message can get through to the mailing list cleanly

Reply via email to