Añadir y modificar campos

From: dass dass <nadedass(at)yahoo(dot)es>
To: pgsql-es-ayuda(at)postgresql(dot)org
Subject: Añadir y modificar campos
Date: 2005-03-01 15:07:28
Message-ID: 20050301150728.77885.qmail@web42203.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-es-ayuda

Estoy usando la version 7.3.2
Esta es mi funcion:

CREATE OR REPLACE FUNCTION "public"."constipo" (text) RETURNS SETOF
tipo AS' SELECT * FROM TIPO WHERE tipo_ctab = $1
'LANGUAGE 'sql' VOLATILE CALLED ON NULL INPUT SECURITY INVOKER;
la tabla tipo es:
tipo_codi char (3)
tipo_item char (3)
tipo_valor DOUBLE PRECISION

Algunos campos:

tipo_codi tipo_item char (3) tipo_valor
TDO 000 10.5
TDO 001 9.5
TPR 000 7.6

Asi llamo a la funcion:
select * from constipo('TDO')

Antes la tabla no tenia el campo tipo_valor, y funcionaba bien, luego q se añadio este campo cuando se llama a la funcion da el siguiente error:

"Query-specified return tuple and actual function return tuple do not
match"


Gracias.


---------------------------------

Responses

Browse pgsql-es-ayuda by date

  From Date Subject
Next Message Roberto Cesar Najera 2005-03-01 15:26:19 instalar dbmirror
Previous Message Oswaldo Hernández 2005-03-01 14:44:35 Re: como manejar selects recursivos?