views:

83

answers:

2

Below cursor declaration works with 5.0 but not with 5.1.

DECLARE CUR_GBLVAR CURSOR FOR SHOW GLOBAL VARIABLES;

A: 

You can accomplish this in MySQL 5.1 as follows:

DECLARE CUR_GBLVAR CURSOR FOR 
SELECT VARIABLE_NAME, VARIABLE_VALUE
FROM INFORMATION_SCHEMA.GLOBAL_VARIABLES
ORDER BY VARIABLE_NAME;
Ike Walker
A: 

Thanks for reply. I already got it from here: http://bugs.mysql.com/bug.php?id=49758

kv