このストアドプロシージャを作成しようとしています:
CREATE PROCEDURE GetExif
(
IN @album VARCHAR(50),
IN @pic VARCHAR(50)
)
BEGIN
SELECT CAMERA,
FSTOP,
EXPOSURE,
ISO,
FOCALLENGHT,
DATETAKEN,
GPSLATH,
GPSLONG
FROM EXIF
WHERE ALBUMNAME = @album
AND PICTURENAME = @pic
END
このエラーが発生します
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '@album VARCHAR(50), IN @pic VARCHAR(50) ) BEGIN
SELECT CAMERA, FSTOP, ' at line 3
選択は正常に機能します。
MySqlServerversionは5.0.51a-logです
@s imを削除した後、このエラーが発生します
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'END' at line 20