functiongetTheNum(){var str = document.getElementById('str').value;//单词、空格、数组、其他的数量var word =0;var space =0;var num =0;var other =0;for(var i =0; i < str.length; i++){//通过检测该元素的ASCII码来判断if((str[i].charCodeAt()>=65&& str[i].charCodeAt()<=90)||(str[i].charCodeAt()>=97&& str[i].charCodeAt()<=122)){word++;}elseif(str[i].charCodeAt()>=48&& str[i].charCodeAt()<=57){num++;}elseif(str[i].charCodeAt()==32){space++;}else{other++;}}console.log('字符:'+ word +'空格:'+ space +'数字:'+ num +'其他:'+ other);}
今天来说说 MySQL 主从复制数据不一致的问题,通过几个具体的案例,来向小伙伴们展示 binlog 不同 format 之间的区别。
1. 准备工作
以下配置基于 Docker。
我这里有一张简单的图向大伙展示 MySQL 主从的工作方式: 这里,我们准备…