link & stored procedures problem
Steven Ophalvens
silversoft at skynet.be
Tue Mar 25 05:25:27 CDT 2008
Hello all,
I am having some problems with a stored procedure that needs to link some
records.
It fails on the line with the link statement, telling me that the closing
bracket ')'
after 'idtestresult' in the first link statement is an unexpected token :
11:18:58: Error: Kernel error: 0x71000. line 18:27: unexpected token: )
----------
Create or replace procedure [sp_answer_question](
IN correct boolean,
IN testId long,
IN VraagID long,
IN IdStudentTest long,
in gebruikerID long)
BEGIN
declare idtestresult long;
declare idtestvraag long;
insert into test_resultaten (juist) values (correct);
set idtestresult = SELECT Last_RecID('lpserver') as id;
set idtestvraag = select id from testVragen where test_id=testId and
vraag_id =VraagID;
link record (idtestresult) of test_resultaten
with record idtestvraag of testVragen
using link_test_resultaat_vraag;
link record (idtestresult) of test_resultaten
with record (IdStudentTest) of studenten_testen
using link_stud_test_resultaten;
END
----------
Am I doing something wrong, if so, what would that be?
Thanks for your help!
Greetings,
Steven Ophalvens
More information about the Valentina
mailing list