代码改变世界

mysql补集合计算

2013-10-14 18:10 by Paddle Zhou, 792 阅读, 0 推荐, 收藏, 编辑
摘要:mysql补集计算方法:两表是1对多关系,user_id是关联字段,两表的数据量都是千万级别的 子查询实现select count(*),sum(total_money) fromA wwhere user_id not in (select user_id from B)耗时为75s 表连接实现select count(*),sum(total_money) from A left join... 阅读全文

在Tomcat中配置基于springside的项目

2013-07-26 16:46 by Paddle Zhou, 302 阅读, 0 推荐, 收藏, 编辑
摘要:注意点:Tomcat默认没有配置Transaction,需要在/Conf/Context.xml配置1如果加载的程序较大,避免内存不够,需要在/bin/Catalina.bat中,行 rem-----ExecuteTheRequestedCommand--------------------------------------- 下面加上1set JAVA_OPTS=%JAVA_OPTS% -se... 阅读全文

Struts升级到2.3.15.1抵抗漏洞

2013-07-23 17:56 by Paddle Zhou, 2040 阅读, 1 推荐, 收藏, 编辑
摘要:后知后觉,今天才开始修复Struts2的漏洞 详细情形可以参考:http://struts.apache.org/release/2.3.x/docs/security-bulletins.html本次的升级是把struts2.3.1.2升级到2.3.15.1全部更新:​1234567891011121314151617181920212223242526272829303132333435363... 阅读全文

Build Firefox 编译Firefox

2013-07-19 11:47 by Paddle Zhou, 1713 阅读, 0 推荐, 收藏, 编辑
摘要:准备 选择需要的firefox版本http://hg.mozilla.org/releases/ 选择最新的build工具http://ftp.mozilla.org/pub/mozilla.org/mozilla/libraries/win32/ 如果是windows系统的话,配置相应的环境(主要是安装vs版本)https://developer.mozilla.org/en-US... 阅读全文

Setup Project 安装项目

2013-07-18 16:34 by Paddle Zhou, 3560 阅读, 0 推荐, 收藏, 编辑
摘要:从vs2012起,微软已经不支持setup project了。以此纪念一下setup project。在新建Setup Project增加安装内容,通常是直接Oupput一个项目,或者直接添加exe,dllFile System中,可以选择程序安装的目录。注意一点,Setup Project本身不提供卸载的功能。需要自己添加。可以在Application Folder添加Uninstall.bat... 阅读全文

WebService中控制字符的处理

2013-07-09 22:09 by Paddle Zhou, 663 阅读, 0 推荐, 收藏, 编辑
摘要:情景最近项目中很多WebService都发不出去,报的错误如下: Invalid white space character in text to output (in xml 1.1, could output as a character entity) 代码如下private String excuteRealTimeExchange(PadisPackageType reqPack... 阅读全文

高性能web之页面缓存

2013-03-08 15:17 by Paddle Zhou, 250 阅读, 0 推荐, 收藏, 编辑
摘要:Expires:过期时间。 告诉浏览器内容何时过期,暗示浏览器在过期时间之前不需要询问服务器。格式: Expires: Thu, 01 Dec 1994 16:00:00 GMT Expires有不足,就是服务器跟客户端的时间可能不一样。所以有了 Cache-Control:Max-age=<second>Web服务器在开启Expires的同时,也会自动添加 Cache-Control浏览器会优先... 阅读全文

转载:JQueryMobile + PhoneGap 经验总结

2013-01-25 15:26 by Paddle Zhou, 772 阅读, 0 推荐, 收藏, 编辑
摘要:原文链接:JQueryMobile + PhoneGap 经验总结http://imyelo.com/?p=2361. pageinit & pageshowJQM的官方手册重点提醒了使用$(document).bind(‘pageinit’)代替$(document).ready()。但当你需要对某一个页面(page)编写其独享的Javascript脚本时, 选择器应该选择的是该page层, 而不是document, 并使用live()添加事件处理器。这在ajaxEnable=true的情况下尤为重要。View DemoJS :$(document).bind('pagein 阅读全文

Html5 Web worker 不能使用 web sql

2013-01-21 16:59 by Paddle Zhou, 326 阅读, 0 推荐, 收藏, 编辑
摘要:因为安全原因,现在Web worker只能用postMessage与主线程通讯,使用XMLHttpRequest,其他的诸如DOM操作,Web sql,LocalStorage都操作不了 阅读全文

HTML5 Databases 详解

2013-01-11 16:25 by Paddle Zhou, 321 阅读, 0 推荐, 收藏, 编辑
摘要:4.1DatabasesEachoriginhas an associated set of databases. Each database has a name and a current version. There is no way to enumerate or delete the databases available for an origin from this API.Each database has one version at a time; a database can't exist in multiple versions at once. Versi 阅读全文