Re: Conditionals
I have done some more work on this and have come up with modified code as below. This seems to satisfy MySQL Workbench but when I run it in my application it says sp3 (the procedure name) is already in use.
I have no need for the procedure at all, I am putting it in because I get an error message if I leave it out.
How do I get around the "sp3 in use" error?
Thanks.
Mike
DELIMITER $$
CREATE PROCEDURE sp3 (x VARCHAR(5))
BEGIN
DECLARE V1 INT DEFAULT 0;
SELECT @mnewnumber := Nextra5 from Storage01 ;
SELECT count(ITEM) FROM Invoices01 as V1 where invnbr > 0;
IF V1 = 0 THEN
update Invoices01 set invnbr = @mnewnumber;
END IF;
END $$
DELIMITER ;
Subject
Written By
Posted
Re: Conditionals
March 14, 2023 12:09AM
Sorry, only registered users may post in this forum.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.