Re: [GENERAL] inner join problem with temporary tables

2007-06-14 Thread Pavel Stehule
2007/6/14, guillermo arias <[EMAIL PROTECTED]>: could you please give me an example?. How could i make an inner join select with temporary tables? This function does not work: REATE OR REPLACE FUNCTION modelo.test2(OUT xart_cod character varying, OUT xart_descri character varying) RETURNS SE

Re: [GENERAL] inner join problem with temporary tables

2007-06-13 Thread guillermo arias
could you please give me an example?. How could i make an inner join select with temporary tables? This function does not work: REATE OR REPLACE FUNCTION modelo.test2(OUT xart_cod character varying, OUT xart_descri character varying) RETURNS SETOF record AS $BODY$ begin create temp table t_art

Re: [GENERAL] inner join problem with temporary tables

2007-06-13 Thread Alvaro Herrera
PFC wrote: > > >This message appears: > > > >ERROR: relation "t_arti" does not exist > >SQL state: 42P01 > >Context: SQL function "test1" > > > > > >Why it does not work??? > >thanks for your help > > Because plpgsql functions are compiled on first execution and all > queries are th

Re: [GENERAL] inner join problem with temporary tables

2007-06-13 Thread PFC
This message appears: ERROR: relation "t_arti" does not exist SQL state: 42P01 Context: SQL function "test1" Why it does not work??? thanks for your help Because plpgsql functions are compiled on first execution and all queries are then prepared. All tables are referenced directly in pre

[GENERAL] inner join problem with temporary tables

2007-06-13 Thread guillermo arias
Hi people, i have a problem with inner join and temporary tablesI have 2 tables: articles and existencesarticles CREATE TABLE public.articles(  art_cod character varying(5) NOT NULL DEFAULT ''::character varying,  art_descri character varying(20) DEFAULT ''::character varying,  CONSTRAINT articles_