By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,811 Members | 1,978 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,811 IT Pros & Developers. It's quick & easy.

Error trigger

P: n/a
I have a trigger when I executed I get this error:

WARNING: Error occurred while executing PL/pgSQL function
actualizar_pagos_comisiones
WARNING: line 19 at select into variables
ERROR: Unable to identify an operator '=' for types 'character' and
'character varying'
You will have to retype this query using an explicit cast

who varchar;

who:=cast($1 as varchar) || $2;

The line 19 is this
SELECT INTO registro * from t_pagos_comisiones where f_wholetipoagnivel =
who and f_fecha = $4;
*-------------------------------------------------------*
*-Edwin Quijada
*-Developer DataBase
*-JQ Microsistemas
*-809-747-2787
* " Si deseas lograr cosas excepcionales debes de hacer cosas fuera de lo
comun"
*-------------------------------------------------------*

__________________________________________________ _______________
¿Estás buscando un auto nuevo? http://www.yupimsn.com/autos/
---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

Nov 11 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On Tue, 16 Sep 2003, Edwin Quijada wrote:

You need for all non varchar items in select cast to varchar. Try
CAST(column AS VARCHAR) or column::VARCHAR;

regards

Pavel
I have a trigger when I executed I get this error:

WARNING: Error occurred while executing PL/pgSQL function
actualizar_pagos_comisiones
WARNING: line 19 at select into variables
ERROR: Unable to identify an operator '=' for types 'character' and
'character varying'
You will have to retype this query using an explicit cast

who varchar;

who:=cast($1 as varchar) || $2;

The line 19 is this
SELECT INTO registro * from t_pagos_comisiones where f_wholetipoagnivel =
who and f_fecha = $4;
*-------------------------------------------------------*
*-Edwin Quijada
*-Developer DataBase
*-JQ Microsistemas
*-809-747-2787
* " Si deseas lograr cosas excepcionales debes de hacer cosas fuera de lo
comun"
*-------------------------------------------------------*

__________________________________________________ _______________
¿Estás buscando un auto nuevo? http://www.yupimsn.com/autos/
---------------------------(end of broadcast)---------------------------
TIP 7: don't forget to increase your free space map settings

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to ma*******@postgresql.org so that your
message can get through to the mailing list cleanly

Nov 11 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.