﻿<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>语源科技BlogJava-ann</title><link>http://www.blogjava.net/ann/</link><description>冰是没有未来的，因为它的永恒</description><language>zh-cn</language><lastBuildDate>Thu, 30 Apr 2026 06:26:34 GMT</lastBuildDate><pubDate>Thu, 30 Apr 2026 06:26:34 GMT</pubDate><ttl>60</ttl><item><title> SQL like子句的另一种实现方法,速度比like快</title><link>http://www.blogjava.net/ann/archive/2010/05/04/320032.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 04 May 2010 04:58:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2010/05/04/320032.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: <br><br>SQL like子句的另一种实现方法,速度比like快<br><br><br>  一般来说使用模糊查询，大家都会想到LIKE<br>      select * from table where a like '%字符%'<br> <br>  如果一个SQL语句中用多个 like模糊查询，并且记录条数很大，那速度一定会很慢。<br>  下面两种方法也可实现模糊查询：<br>      select * from table where patindex('%字符%',a)>0<br>      select * from table where charindex('字符',a)>0<br>   经测试这两种方法比LIKE速度要快。<br><br>&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2010/05/04/320032.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/320032.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2010-05-04 12:58 <a href="http://www.blogjava.net/ann/archive/2010/05/04/320032.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>postgres create INDEX</title><link>http://www.blogjava.net/ann/archive/2009/12/22/306875.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 22 Dec 2009 02:00:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/12/22/306875.html</guid><description><![CDATA[<tt>&nbsp;&nbsp; CREATE INDEX</tt> 在指定的表上构造一个名为
<tt><em>index_name</em></tt>
的索引。索引主要用来提高数据库性能。但是如果不恰当的使用将导致性能的下降。<br />
<p>&nbsp;&nbsp;	PostgreSQL
为从索引提供 B-tree，R-tree，hash（散列） 和 GiST 索引方法。
B-tree 索引方法是一个 Lehman-Yao 高并发 B-trees 的实
现。R-tree 索引方法用 Guttman 的二次分裂算法实现了标准的 R-trees。
hash（散列）索引方法是 Litwin 的线性散列的一个实现。
用户也可以定义它们自己的索引方法，但这个工作相当复杂。
</p>
&nbsp;&nbsp;	如果出现了 <tt>WHERE</tt> 子句，则创建一个<em>部分索引</em>。
部分索引是一个只包含表的一部分记录的索引，通常是该表中比其它部分数据更有用的部分。
<br />
<p>&nbsp;&nbsp;	在 <tt>WHERE</tt> 子句里用的表达式只能引用下层表的字段，但是它可以使用所有字段，而不仅仅是被索引的字段。
目前，子查询和聚集表达式也不能出现在<tt>WHERE</tt>里。
</p>
<p>&nbsp;&nbsp;	索引定义里的所有函数和操作符都必须是<em>immutable</em>，（不变的）也就是说，
它们的结果必须只能依赖于它们的输入参数，而决不能依赖任何外部的影响（比如另外一个表的内容或者当前时间）。
这个约束确保该索引的行为是定义完整的。要在一个索引上使用用户定义函数，请记住在你创建它的时候把它标记为immutable的函数。 <br />
</p>
<p>&nbsp;&nbsp; 目前，只有 B-tree 和 gist 索引方法支持多字段索引。
缺省时最多可以声明 32 个键字（这个限制可以在制作 PostgreSQL 时修改）。
目前只有 B-tree 支持唯一索引。
</p>
可以为索引的每个列/字段声明一个 <em>操作符表</em>。
操作符表标识将要被该索引用于该列/字段的操作符。
例如， 一个四字节整数的 B-tree 索引将使用 <tt>int4_ops</tt> 表；
这个操作符表包括四字节整数的比较函数。 实际上，该域的数据类型的缺省操作符表一般就足够了。
某些数据类型有操作符表的原因是，它们可能有多于一个的有意义的顺序。
例如，我们对复数类型排序时有可能以绝对值或者以实部。
我们可以通过为该数据类型定义两个操作符表，然后在建立索引的时候选择合适的表来实现。<br />
<br />
<br />
http://www.postgresql.org/docs/8.4/interactive/index.html<br />
<p>  </p>
<br />
<img src ="http://www.blogjava.net/ann/aggbug/306875.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-12-22 10:00 <a href="http://www.blogjava.net/ann/archive/2009/12/22/306875.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>java jar </title><link>http://www.blogjava.net/ann/archive/2009/12/22/306873.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 22 Dec 2009 01:47:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/12/22/306873.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: java -cp "./WEB-INF/lib/*:./WEB-INF/classes" bran.RestaurantCenterJettyStarter&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2009/12/22/306873.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/306873.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-12-22 09:47 <a href="http://www.blogjava.net/ann/archive/2009/12/22/306873.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>nginx ssi设置</title><link>http://www.blogjava.net/ann/archive/2009/12/22/306872.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 22 Dec 2009 01:35:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/12/22/306872.html</guid><description><![CDATA[<h2>一个登录用户在页面访问的时候如何充分利用 cache?</h2>
<p>页面静态化的一个大问题是登录用户访问页面如何静态化。 例如首页， 大部分的页面内容需要缓存但是用户登录后的个人信息是动态信息， 不能缓存。 那么如何解决这个"页面部分缓存"问题？</p>
<p>现有的方案是利用 <a href="http://en.wikipedia.org/wiki/Server_Side_Includes">SSI - Server Side include<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a>.</p>
<p>Nginx SSI 实现是  <a href="http://wiki.nginx.org/NginxHttpSsiModule">http://wiki.nginx.org/NginxHttpSsiModule<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></p>
<p>这里最关键的就是静态文件可以包含一个动态的网页的 URL.</p>
<p>这里有一篇文章对这个问题进行了深入的讨论：</p>
<p><a href="http://jimmyg.org/blog/2009/ssi-memcached-nginx.html">http://jimmyg.org/blog/2009/ssi-memcached-nginx.html<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></p>
<p>文章用了 memcache. 我关心的是 SSI 和 Nginx 自身的 cache 的协同工作。</p>
<p><br />
</p>
<p>模块分析：</p>
<ol>
    <li><a href="http://hi.baidu.com/langwan/blog/item/c6399513c19a4f896438db72.html">http://hi.baidu.com/langwan/blog/item/c6399513c19a4f896438db72.html<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></li>
    <li><a href="http://hi.baidu.com/langwan/blog/item/d4c40efa6752ad9e59ee90c5.html">http://hi.baidu.com/langwan/blog/item/d4c40efa6752ad9e59ee90c5.html<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></li>
</ol>
<p><a href="http://kovyrin.net/2007/08/05/using-nginx-ssi-and-memcache-to-make-your-web-applications-faster/">http://kovyrin.net/2007/08/05/using-nginx-ssi-and-memcache-to-make-your-web-applications-faster/<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></p>
<p><a href="http://www.misuse.org/science/2008/02/22/rails-page-caching-nginx-ssi-ajax-and-form-posts/#more-118">http://www.misuse.org/science/2008/02/22/rails-page-caching-nginx-ssi-ajax-and-form-posts/#more-118<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></p>
<div id="comment-11741-closed" style="display: none;">
<div style="background: rgb(240, 240, 240) none repeat scroll 0% 0%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial;">
<div subtext="" smallgrey="">
[ <a href="http://etch1/jira/browse/CORNER-39" onclick="toggleDivsWithCookie('comment-11741-open', 'comment-11741-closed'); return false;" class="smallgrey">Show &#187;</a> ]
</div>
<div style="overflow: hidden; height: 1em;">
<a href="http://etch1/jira/secure/ViewProfile.jspa?name=bran">冉兵</a> - 01/十一月/09 06:39 下午   - <span subtext="" title="冉兵 - 01/十一月/09 07:17 下午">edited</span>              ref:
模块分析：
<ol>
    <li><a href="http://hi.baidu.com/langwan/blog/item/c6399513c19a4f896438db72.html">http://hi.baidu.com/langwan/blog/item/c6399513c19a4f896438db72.html<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></li>
    <li><a href="http://hi.baidu.com/langwan/blog/item/d4c40efa6752ad9e59ee90c5.html">http://hi.baidu.com/langwan/blog/item/d4c40efa6752ad9e59ee90c5.html<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a></li>
</ol>
<a href="http://kovyrin.net/2007/08/05/using-nginx-ssi-and-memcache-to-make-your-web-applications-faster/">http://kovyrin.net/2007/08/05/using-nginx-ssi-and-memcache-to-make-your-web-applications-faster/<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a>
<a href="http://www.misuse.org/science/2008/02/22/rails-page-caching-nginx-ssi-ajax-and-form-posts/#more-118">http://www.misuse.org/science/2008/02/22/rails-page-caching-nginx-ssi-ajax-and-form-posts/#more-118<sup><img src="http://etch1/jira/images/icons/linkext7.gif" alt="" align="absmiddle" border="0" height="7" width="7" /></sup></a>     </div>
</div>
</div>
<img src ="http://www.blogjava.net/ann/aggbug/306872.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-12-22 09:35 <a href="http://www.blogjava.net/ann/archive/2009/12/22/306872.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>openmq 集群配置</title><link>http://www.blogjava.net/ann/archive/2009/12/22/306871.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 22 Dec 2009 01:32:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/12/22/306871.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: 一 . Adding Brokers to a Conventional Cluster<br><br>  1. To Add a New Broker to a Conventional Cluster Using a Cluster Configuration File<br>     1).Add the new broker to the imq.cluster.brokerlist property in the cluster configuration file.<br>     2).Issue the following command to any broker in the cluster: imqcmd reload cls<br>     3).(Optional) Set the value of the imq.cluster.url property in the new broker’s instance configuration file            (config.properties) to point to the clu&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2009/12/22/306871.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/306871.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-12-22 09:32 <a href="http://www.blogjava.net/ann/archive/2009/12/22/306871.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>grails quartz</title><link>http://www.blogjava.net/ann/archive/2009/12/11/305580.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Fri, 11 Dec 2009 07:56:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/12/11/305580.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: http://svn.codehaus.org/grails-plugins/grails-quartz/tags/RELEASE_0_4_1/&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2009/12/11/305580.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/305580.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-12-11 15:56 <a href="http://www.blogjava.net/ann/archive/2009/12/11/305580.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>solr</title><link>http://www.blogjava.net/ann/archive/2009/12/11/305541.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Fri, 11 Dec 2009 04:43:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/12/11/305541.html</guid><description><![CDATA[http://lucene.apache.org/solr/tutorial.html
<img src ="http://www.blogjava.net/ann/aggbug/305541.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-12-11 12:43 <a href="http://www.blogjava.net/ann/archive/2009/12/11/305541.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>nginx聊天module --NGiNX_HTTP_Push_Module</title><link>http://www.blogjava.net/ann/archive/2009/11/20/303024.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Fri, 20 Nov 2009 03:29:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/11/20/303024.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: nginx 聊天室模块&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2009/11/20/303024.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/303024.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-11-20 11:29 <a href="http://www.blogjava.net/ann/archive/2009/11/20/303024.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>nginx0.8.8  purge_cache module 中出现...is too small...</title><link>http://www.blogjava.net/ann/archive/2009/11/17/302729.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 17 Nov 2009 09:59:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/11/17/302729.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: nginx 重启之后 用purge 会出现以上错误<br>nginx log ：<br>2009/11/17 15:03:52 [crit] 1553#0: *1 cache file "/data/nginx_cache/etwebservice/a/2b/b3a2527b6f3a38d63663ee436e7d82ba" is too small, client: 222.66.142.229, server: localhost, request: "HEAD /purge/RestTakeoutServer/dish/B10I24R57547/list?commentCount=5 HTTP/1.1", host: "222.66.142.229"<br><br>客户端请求出错<br><br>HTTP/1.1 500 Internal Server Error<br>Server: nginx/0.8.24<br>Date: Tue, 17 Nov 2009 07:03:52 GMT<br>Content-Type: text/html<br>Content&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2009/11/17/302729.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/302729.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-11-17 17:59 <a href="http://www.blogjava.net/ann/archive/2009/11/17/302729.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item><item><title>nginx0.8.26 加入 purge_cache module</title><link>http://www.blogjava.net/ann/archive/2009/11/17/302727.html</link><dc:creator>冰是没有未来的，因为它的永恒</dc:creator><author>冰是没有未来的，因为它的永恒</author><pubDate>Tue, 17 Nov 2009 09:45:00 GMT</pubDate><guid>http://www.blogjava.net/ann/archive/2009/11/17/302727.html</guid><description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp; 摘要: nginx0.8.26 加入 purge_cache module&nbsp;&nbsp;<a href='http://www.blogjava.net/ann/archive/2009/11/17/302727.html'>阅读全文</a><img src ="http://www.blogjava.net/ann/aggbug/302727.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.blogjava.net/ann/" target="_blank">冰是没有未来的，因为它的永恒</a> 2009-11-17 17:45 <a href="http://www.blogjava.net/ann/archive/2009/11/17/302727.html#Feedback" target="_blank" style="text-decoration:none;">发表评论</a></div>]]></description></item></channel></rss>