Stored Procedure too slow
Hi all,
I've created a very simple Stored procedure, with a single insert statement in a table with autoincrement PK.
To test the performances, I tried to call this SP fro another SP, written in this way:
CREATE PROCEDURE `testAddPhysNode`(
IN _iterations INT,
IN _startIter INT,
IN _netID INT
)
BEGIN
DECLARE _type INT;
DECLARE _newid INT; --this is output param
DECLARE _creat BIT; --this is output param
SET _type = _startIter;
WHILE (_type < (_startIter + _iterations)) DO
CALL AddPhysNode(1, 123, 1, 'test', 0x1234, 0x1256,
_netID, 1, _type, _newid, _creat);
SET _type = _type + 1;
END WHILE;
END
which results in an average computation time of the AddPhysNode SP of 10 millisec.
Now my question is: are 10 milliseconds a usual time for the invocation of a simple SP?
If not, am I missing anything? Is my benchmark realistic?
Thank you very much
Best
cghersi