Mysql-MYSQLPROCEDURE problem Emergency SOS thank you

Source: Internet
Author: User
I copied the creation statement of a stored procedure, deleted it, and re-created it. The result was always an error, and a syntax error was reported. I still did not find the error, SOS, thank you for the error message. The line I added was [Err] 1064 mysql.

I copied the creation statement of a stored procedure, deleted it, and re-created it. The result was always an error, and the syntax error was reported. no error was found in the end, SOS. thank you!
The line I added in bold

[Err] 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 ''at line 30

Create definer = 'root' @ 'loaclhost' PROCEDURE 'p _ SIG_INFO_MANAGEMENT '(IN vi_db_method VARCHAR (253), IN vi_sig_id VARCHAR (253), IN vi_sig_name_cn VARCHAR (253) character set utf8, IN bytes VARCHAR (253), IN vi_sig_action_id INT (11), IN vi_sig_protocol VARCHAR (253), IN vi_sig_version VARCHAR (8), IN vi_sig_encrypt DECIMAL (1 ), IN vi_sig_direction VARCHAR (253), IN vi_sig_port VARCHAR (253), IN vi _ Sig_type VARCHAR (253), IN vi_sig_priority INT (11), IN vi_sig_option DECIMAL (1), IN vi_sig_genlog INT (11), IN vi_sig_match_main VARCHAR (1024 ), -- IN vi_sig_match_2 VARCHAR (1024), -- IN vi_sig_match_3 VARCHAR (1024), IN every DECIMAL (1), -- IN vi_sig_createtime DATETIME, -- IN vi_sig_modifytime DATETIME, IN every VARCHAR (253 ), IN vi_sig_author_list VARCHAR (1024), IN vi_sig_update _ History TEXT, IN vi_sig_desc TEXT, IN vi_sig_status DECIMAL (1), IN vi_sig_app_id INT (11), IN vi_sig_usrc_corevent DECIMAL (1) COMMENT 'application feature information record-management process. 'In in -- local val declared. -- ** DECLARE _ ERR_NUM INT (11); ** DECLARE _ ERR_MSG VARCHAR (253); DECLARE vi_sig_createtime TIMESTAMP; DECLARE vi_sig_modifytime TIMESTAMP; -- initial local val. SET _ ERR_NUM = 0; SET _ ERR_MSG = ""; -- default val given. SET vi_sig_createtime = CURRENT_TIME; SET vi_sig_modifytime = CURRENT_TIME; -- parameters security check. -- IF (vi_sig_author is null) then set _ ERR_NUM = 2; SET _ ERR_MSG = 'the user who modified this application IS unknown. '; ELSEIF (! STRCMP (vi_sig_author, "sapling") then set _ ERR_NUM = 11; SET _ ERR_MSG = 'system administrator [sapling] cannot operate on the database. '; end if; -- start to do standard mission. IF (! STRCMP (vi_db_method, "INSERT") then if (vi_sig_id is null) then set @ SIG_NUM_START = 16777216; -- (Hex: 0x0100 0000 Dec: 16777216) -- start to auto generate a sig id to keep unique. select count (T_SIG_ID) INTO vi_sig_id FROM 'sap _ all_assist_sigs '; -- calculate the total number of features of the current application --> 10 to SET vi_sig_id = @ SIG_NUM_START + vi_sig_id + 1; -- calculate the newly added feature ID --> 10 into SET vi_sig_id = CONCAT ("0x0", CONV (vi_sig_id, 10, 16); -- convert in hexadecimal format, and splice the standard header 0x0 --> to form a feature ID such as: 0x01001001. end if; -- start to do insert. insert into 'sap _ timeout' (T_SIG_ID, inflow, inflow, T_SIG_ACTION_ID, inflow, T_SIG_VERSION, inflow, T_SIG_DIRECTION, T_SIG_PORT, T_SIG_TYPE, inflow, T_SIG_OPTION, inflow, T_SIG_CREATETIME, t_SIG_MODIFYTIME, T_SIG_AUTHOR, T_SIG _ AUTHOR_LIST, numbers, T_SIG_DESC, T_SIG_STATUS, T_SIG_APP_ID, numbers) VALUES (vi_sig_id, audience, audience, -- Application feature ID, Chinese and English triplet VALUES, audience, vi_sig_version, audience, audience, vi_sig_port, -- Port, direction option dual group vi_sig_type, vi_sig_priority, vi_sig_option, vi_sig_genlog, vi_sig_match_main, vi_sig_audit_support, vi_sig_createtim E, vi_sig_modifytime, -- system time, automatically calculate vi_sig_author, vi_sig_author_list. -- The former is the current logon system account, and the latter is the list of all accounts that have modified this application, namely, region, vi_sig_desc, vi_sig_app_id, vi_sig_usrc_corevent); -- ID of the application to which the application feature belongs. (corresponding to the sap_all_apps table) ELSEIF (! STRCMP (vi_db_method, "UPDATE") then if (vi_sig_id is not null) then update 'sap _ region' SET T_SIG_NAME_CN = Beijing, T_SIG_NAME_EN = Beijing, T_SIG_ACTION_ID = vi_sig_action_id, t_SIG_PROTOCOL = protocol, T_SIG_VERSION = vi_sig_version, direction = direction, T_SIG_DIRECTION = direction, T_SIG_PORT = direction, T_SIG_TYPE = direction, direction = direction, T_SIG_OPTION = vi_sig_option, direction = direction, direction = direction, pipeline = pipeline, -- T_SIG_CREATETIME = vi_sig_createtime, pipeline = pipeline, pipeline = pipeline, T_SIG_AUTHOR_LIST = pipeline, pipeline = pipeline, T_SIG_DESC = pipeline, T_SIG_STATUS = vi_sig_status, T_SIG_APP_ID = pipeline, t_SIG_USRC_COREVENT = vi_sig_usrc_corevent WHERE T_SIG_ID = vi_sig_id; end if; else set _ ERR_NUM = 11; SET _ ERR_MSG = 'system administrator [sapling] cannot operate the database. '; select concat (_ ERR_NUM, ":", _ ERR_MSG); end if; END

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.