Open
Description
Hi,
When I am running Select ... for update
queries ProxySQL does not increase the counter in stats_mysql_commands_counters
table.
Easy to reproduce, check counters:
mysql> select Command,Total_cnt from stats_mysql_commands_counters where Command like '%select%';
+-------------------+-----------+
| Command | Total_cnt |
+-------------------+-----------+
| SELECT | 12 |
| SELECT_FOR_UPDATE | 0 |
+-------------------+-----------+
2 rows in set (0.00 sec)
Run the following query:
select * from sbtest1 where id<10 for update;
Then check the counters again:
mysql> select Command,Total_cnt from stats_mysql_commands_counters where Command like '%select%';
+-------------------+-----------+
| Command | Total_cnt |
+-------------------+-----------+
| SELECT | 13 |
| SELECT_FOR_UPDATE | 0 |
+-------------------+-----------+
2 rows in set (0.00 sec)
As you can see the Select
counter was increased instead of SELECT_FOR_UPDATE
.
I tested it on multiple versions.