CREATE PROCEDURE dasd (
IN aSupplierID varchar(4),
IN aSupplierName varchar(100),
IN aSupplierAddress varchar(255),
IN aSupplierTelPhone varchar(10))
BEGIN
insert
into
supplier
(SupplierID,SupplierName,SupplierAddress,SupplierTelPhone)
values
(aSupplierID,aSupplierName,aSupplierAddress,aSupplierTelPhone);
END
I find an error in the line 'values(aSupplierID,aSupplierName,aSupplierAddress,aSupplierTelPhone); END'.
Please can you try following one
CREATE PROCEDURE dasd (
IN aSupplierID varchar(4),
IN aSupplierName varchar(100),
IN aSupplierAddress varchar(255),
IN aSupplierTelPhone varchar(10))
BEGIN
insert
into
supplier
(SupplierID,SupplierName,SupplierAddress,SupplierTelPhone)
values
(in_aSupplierID,in_aSupplierName,in_aSupplierAddress,in_aSupplierTelPhone);
END
Try this
DELIMITER $$
CREATE PROCEDURE das1d (
IN aSupplierID VARCHAR(4),
IN aSupplierName VARCHAR(100),
IN aSupplierAddress VARCHAR(255),
IN aSupplierTelPhone VARCHAR(10))
BEGIN
INSERT
INTO
supplier
(SupplierID,SupplierName,SupplierAddress,SupplierTelPhone)
VALUES
(aSupplierID,aSupplierName,aSupplierAddress,aSupplierTelPhone);
END$$
DELIMITER ;
The delimiter is changed to $$ to enable the entire definition to be passed to the server as a single statement, and then restored to ; before invoking the procedure. This enables the ; delimiter used in the procedure body to be passed through to the server rather than being interpreted by mysql itself. Click here for more details about defining stored procs.