最新评论

mythzz 2008-07-05 23:34
@springhcq
SARG是一种数据库的自动优化技术吧。书上定义是:用于限制搜索的一个操作,因为它通常是指一个特定的匹配,一个值得范围内的匹配或者两个以上条件的AND连接。
说的通俗点就是能确定范围的,并且不是用到全表扫描。

呵呵 纯粹个人理解。
springhcq 2008-07-04 11:28
您好,能麻烦解释一下文中提到的SARG是什么意思吗
mythzz 2008-03-17 14:19
ip中无,4333
mythzz 2007-08-10 10:30
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Net;
using System.IO;
using System.Text.RegularExpressions;
using System.Text;

public partial class Default2 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

}
protected void Button1_Click(object sender, EventArgs e)
{


string URL = "http://www.myisp.cn/";
string Content = GetHtmlContent(URL);
Regex dx = new Regex("<.+?>");
// string s = dx.Replace(Content, "");
string s = Content;
int tt = s.IndexOf("ICP备");
Response.Write("8-0" + tt);
Response.Write(s);


}









private string GetHtmlContent(string Url)
{
string strHtmlContent = "";
try
{
//声明一个HttpWebRequest请求
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(Url);
//连接超时时间
request.Timeout = 500000;
request.Headers.Set("Pragma", "no-cache");
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
Stream streamHtmlCode = response.GetResponseStream();
Encoding encoding = Encoding.GetEncoding("GB2312");
StreamReader streamReader = new StreamReader(streamHtmlCode, encoding);
strHtmlContent = streamReader.ReadToEnd();
}
catch
{
Response.Write("ERROR");
}
return strHtmlContent;
}


}
任力 2007-08-05 11:37
支持楼主!
任力 2007-08-05 09:10
学习了!呵呵,你在哪弄的这些东西?
mythzz 2007-07-03 14:15

其实 GetObject 就是 从一个文件 或者 对象中取得信息 取得其操作

例如

GetObject("WinNT://.") 这个就是系统对象了~

而假如你系统装了OFFICE的 EXCEL 那我们就可以这样获得对象

Set xls = GetObject("d:\1.xls","Excel.Application") ' 第一参数是 xls的文件路径 第2个参数是对象的类型

也可以让他自动识别

Set xls = GetObject("d:\1.xls")
吴祖纯 2006-10-21 09:35
@吴祖纯LINUX下tar.gz包的安装方法
吴祖纯 2006-10-21 09:34
LINUX下tar.gz包的安装方法
gym 2006-09-07 16:59
OAConfig OAConfig1=new OAConfig();

这个类被封装了,能否提供源代码参考一下如何实现,或者介绍一下函数的应用?
或者给一下简单介绍,介绍一下函数中("/source_file.xls","00",3,"SELECT * FROM [空间$]");
"00" ,3,各代表什么意思?
study 2006-09-01 15:51
怎样建立聚集索引与非聚集索引
mythzz 2006-03-16 20:24
str = "For more information, see Chapter 3.4.5.1";
re = /(chapter \d+(\.\d)*)/i;
found = str.match(re);
是把re中的匹配 用str来代替(在str查找类似re类型,好象是第一个的位置) 有几个左( 就表示有几个子匹配或是分组,具体情况而定
found成为数组 found[0]代表的是整个匹配
found[1]第一个子匹配 第一个左(开始[前面的包括后面匹配的内容]
found[n]第n个子匹配 第一个左(开始


如果没有设置全局标志 (g),found[0] 元素包含整个匹配,而第 1 到 n 元素包含了匹配中曾出现过的任一个子匹配。
mythzz 2006-03-16 20:04
\num 对所获取的匹配的引用。例如,'(.)\1' 匹配两个连续的相同字符。
只有在小括号下面才有\num的引用
比如:
/(.)(.)\1/g; 其实这里的\1 就是对第一个(.)的引用,也就是说这里匹配的是3个字符,而第一个和第三个一定是一样的,比如dcd
/(.)(.)\1\2/ 这里匹配4个字符,第一个和第3个相同,第2个和第4个相同,比如dcdc