这个mysql存储过程有什么问题?

这个mysql存储过程有什么问题?,mysql,stored-procedures,Mysql,Stored Procedures,我使用以下mysql过程 DROP PROCEDURE IF EXISTS `allied`.`GetRegistrationData`$$ CREATE DEFINER=`allied`@`%` PROCEDURE `GetRegistrationData`() BEGIN select aboutUsId,name from aboutus where isDeleted=0 select ageId,name from age where isDeleted=0 select de

我使用以下mysql过程

DROP PROCEDURE IF EXISTS `allied`.`GetRegistrationData`$$
CREATE DEFINER=`allied`@`%` PROCEDURE `GetRegistrationData`()

BEGIN
 select aboutUsId,name from aboutus where isDeleted=0
 select ageId,name from age where isDeleted=0
 select desiredsetId,name from desiredsetting where isDeleted=0
 select disciplineId,name from discipline where isDeleted=0
 select employeementId,name from employeement where isDeleted=0
 select salutationId,name from salutation where isDeleted=0
 select timeId,name from timetocall where isDeleted=0
END$$

DELIMITER ;
当我执行此操作时,会出现一个错误

Error Code : 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 
'select ageId,name from age where isDeleted=0
select desiredsetId,name from desir' at line 4

任何建议…

您遗漏了每行
SELECT
末尾的分号您遗漏了每行
SELECT
末尾的分号您只需用分号终止
SELECT
语句,要修复该错误。

您只需用分号终止
SELECT
语句,即可修复该错误。

SELECT语句不需要结束符
?@pekka可以调整我的存储过程以使其更快,因为有多个select语句。您能告诉我们您试图实现的结果吗?@Daniel我正在使用一个包含7个下拉列表的页面,因此我使用此查询将值绑定到它们……您有性能问题吗?因为如果您需要从7个不同的表中获取数据,这几乎是一种方法。但是,您可能需要重新考虑表的设计。现在还不清楚它应该如何工作。SELECT语句不需要一个结束符
?@pekka可以调整我的存储过程以使其更快,因为有多个select语句。您能告诉我们您试图实现的结果吗?@Daniel我正在使用一个包含7个下拉列表的页面,因此我使用此查询将值绑定到它们……您有性能问题吗?因为如果您需要从7个不同的表中获取数据,这几乎是一种方法。但是,您可能需要重新考虑表的设计。现在还不清楚它应该如何工作。@bala你现在的问题与你原来的问题完全不同。我认为接受其中一个答案(可能扔硬币:)并开始一个新的答案是合适的。@bala你现在的问题与原来的完全不同。我认为接受其中一个答案(可能扔硬币:)并开始一个新的答案是合适的。