mysql优化相关
摘要:逆范式:1对多的时候应当尽可能的把冗余放在1那边show statusshow variables关心以com开头的命令 show status like 'com%'showsession status like 'com_select'; //本次会话show global status like 'com_select'; //从启动到现在show Connections 试图连接数据库的次数show global status like 'uptime'; 服务器启动时间__________________________
阅读全文
posted @
2012-08-31 18:17
思齐_
阅读(275)
推荐(0) 编辑
mysql在创建存储函数时报错
摘要:我们在使用mysql数据库开发项目的时候,有时Mysql系统自带的函数不能完全满足我们开发的需要,解决方法是自己创建函数,可以有可能在你创建函数的过程事会报出Error 1418错误,对于报这种错误的详细信息如所所示出错信息大致类似:ERROR 1418 (HY000): This function has none of DETERMINISTIC, NO SQL, or READS SQL DATA in its declaration and binary logging is enabled (you *might* want to use the less safe log_bin_
阅读全文
posted @
2012-08-31 14:46
思齐_
阅读(939)
推荐(0) 编辑
试题总结(一)
摘要:strcasecmp($_SERVER['REMOTE_ADDR'], 'unknown') //比较两个字符串是否相等,不区分大小写1.写一个函数,尽可能高效的,从一个标准 url 里取出文件的扩展名例如: http://www.sina.com.cn/abc/de/fg.php?id=1 需要取出 php 或 .php function getExt($url){ $arr = parse_url($url); print_r($arr); return strstr($arr['path'],'.'); }2.二维数组排序$
阅读全文
posted @
2012-08-30 15:04
思齐_
阅读(485)
推荐(1) 编辑