我创建了一个简单的存储过程,成功了,但是在call执行调用的时候怎么老是报错呢?求高手
mysql> delimiter //
mysql> create procedure proprice()
-> begin
-> select avg(price) as average from products;
-> end//
Query OK, 0 rows affected (0.02 sec)mysql> delimiter ;错误:
mysql> call proprice();
ERROR 1457 (HY000): Failed to load routine test.proprice. The table mysql.proc i
s missing, corrupt, or contains bad data (internal code -5)
mysql> delimiter //
mysql> create procedure proprice()
-> begin
-> select avg(price) as average from products;
-> end//
Query OK, 0 rows affected (0.02 sec)mysql> delimiter ;错误:
mysql> call proprice();
ERROR 1457 (HY000): Failed to load routine test.proprice. The table mysql.proc i
s missing, corrupt, or contains bad data (internal code -5)
解决方案 »
- Can't create a new thread (errno -1); if you are not out of available memory??
- MYSQL 分页错误了
- 用别名与不用别名进行排序一样吗?
- 急!!!mysql中的部分数据库部分表突然无法查询
- 求助使用MySQL-Front出现在这个错误是什么意思
- 请问:数据库中两个完全相同权限的用户为什么有一个无法写入呢?
- 客户不支持服务器请求的验证协议; 考虑提升MySQL客户,什么意思?大家帮忙
- MySQL 5.0 Windows版本是不是收费的?
- 请教:MySQL连不上了,出现“Lost connection to MySQL server during query”的错误提示!!怎么解决呀!!
- MySQL官方手册(中文)?
- 怎么用sql语句根据ID逐条替换内容?
- 怎么用sql语句根据ID逐条替换内容?
没有数据的原因吧
+---------+
| average |
+---------+
| 15.2625 |
+---------+
1 row in set (0.04 sec)
+---------+
| average |
+---------+
| 15.2625 |
+---------+
1 row in set (0.04 sec)
+-------+
| price |
+-------+
| 1 |
| 2 |
+-------+
2 rows in set (0.00 sec)
mysql> call proprice();
+---------+
| average |
+---------+
| 1.5000 |
+---------+
1 row in set (0.00 sec)Query OK, 0 rows affected (0.00 sec)过程可以执行 楼主 最好贴出数据