[MySql Query Browser]STORED PROCEDURE
Posted: Mon 22 May 2006 15:19
I need to call the stored procedure below, (made in MYSQL QUERY BROWSER) How you can see it delete all record int the table progetti, and I want add the code in this procedure that after delete records, initialize the autoinc field CODICE from 1. How can i do that?
thanks a lot.
DELIMITER $$
DROP PROCEDURE IF EXISTS `sajob`.`DELPROGETTI` $$
CREATE PROCEDURE `DELPROGETTI`()
BEGIN
DELETE FROM progetti;
//inizialise field codice (1)
END $$
DELIMITER ;
thanks a lot.
DELIMITER $$
DROP PROCEDURE IF EXISTS `sajob`.`DELPROGETTI` $$
CREATE PROCEDURE `DELPROGETTI`()
BEGIN
DELETE FROM progetti;
//inizialise field codice (1)
END $$
DELIMITER ;