DEFINE result row(mountain varchar(128),climber varchar(128),year
int);
FOREACH
SELECT *
INTO result
FROM ontop
WHERE climber=c
RETURN result
WITH RESUME;
END FOREACH;
END PROCEDURE;
But when trying too execute this (execute procedure climbertops('Josef
Rakoncaj');) I get the message:
9628: Type () not found.
I've tried to declare host variable to execute function into this
variable:
EXEC SQL BEGIN DECLARE SECTION;
row(varchar(128), varchar(128), int) climber;
EXEC SQL END DECLARE SECTION;
execute function climbertops('Josef Rakoncaj') into :climber;
but I always get " 201: A syntax error has occurred." error.
Even simple copy and paste from Informix tutorial (
EXEC SQL BEGIN DECLARE SECTION;
int p_int;
EXEC SQL END DECLARE SECTION;
) causes the same error.
Can anybody help me with this (for sure) easy problem?
Agata
thanx
Prasad
Another solution I got, was to declare new row type:
CREATE ROW TYPE result_rt (mountain varchar(128),climber varchar
(128),year int);