hola compaƱeros!!
hoy me asalto otra duda sobre como elaborar una funcion de postgres usando
PLPGSQL,
me e percatado que los fetch en ocaciones son demasiado tardados y queria
usar en lugar de
los cursores un tipo ARRAY de hecho hice la siguiente funcion de prueba
REATE OR REPLACE FUNCTION procmty."array"()
RETURNS integer AS
$BODY$
DECLARE
v TEXT ARRAY;
BEGIN
select control from procmty.uploader into v;
RAISE NOTICE '%',nombre_tabla;
RETURN NULL;
END;
$BODY$
LANGUAGE 'plpgsql' VOLATILE
COST 100;
ALTER FUNCTION procmty."array"() OWNER TO postgres;
pero al correrla me marca la siguiente
ERROR: array value must start with "{" or dimension information
CONTEXT: PL/pgSQL function "array" line 4 at SQL statement
Si alguien me puede orientar muchas gracias!!!