上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 14 下一页
  2012年9月17日
摘要: //实现json的序列化和反序列化 Person Person = new Person(); Person.Id = 1; Person.Name = "小白"; DataContractJsonSerializer json = new DataContractJsonSerializer(Person.GetType()); string szJson = ""; //序列化 using (MemoryStream stream = new MemoryStream()) { jso... 阅读全文
posted @ 2012-09-17 10:32 jameshappy 阅读(402) 评论(0) 推荐(0) 编辑
摘要: //实现http访问 try { string getpage = @"http://192.168.0.36:8082/News/PlusNews.aspx"; CookieContainer cc = new CookieContainer(); string content = string.Empty; HttpWebRequest request = (HttpWebRequest)WebRequest.Create(getpage); request.Method = "post"; ... 阅读全文
posted @ 2012-09-17 10:30 jameshappy 阅读(294) 评论(0) 推荐(0) 编辑
  2012年9月13日
摘要: int actual = 0; string strSql = "select producthtml from web_goods where productsn=835"; OracleDataReader reader= OraHelper.ExecuteReader(OraHelper.CONN_STRING, CommandType.Text, strSql, null); while (reader.Read()) { OracleLob myOracleClob = reader.GetOracleLob(0); StreamReader streamread 阅读全文
posted @ 2012-09-13 15:59 jameshappy 阅读(1596) 评论(0) 推荐(0) 编辑
摘要: OraHelper OraHelper = new OraHelper(); private void btnRead_Click(object sender, EventArgs e) { string[] strFiles = Directory.GetFiles(@"E:\网站\百联项目\goodshtml"); string strProductid = string.Empty; string strSql = string.Empty; string output = string.Empty; foreach(string strFile in strFile 阅读全文
posted @ 2012-09-13 10:50 jameshappy 阅读(261) 评论(0) 推荐(0) 编辑
摘要: VARCHAR2(size) 可变长度的字符串,其最大长度为size个字节;size的最大值是4000,而最小值是1;你必须指定一个VARCHAR2的size; NVARCHAR2(size) 可变长度的字符串,依据所选的国家字符集,其最大长度为size个字符或字节;size的最大值取决于储存每个字符所需的字节数,其上限为4000;你必须指定一个NVARCHAR2的size; NUMBER(p,s) 精度为p并且数值范围为s的数值;精度p的范围从1到38;数值范围s的范围是从-84到127; 例如:NUMBER(5,2) 表示整数部分最大3位,小数部分为2位; NUMBER(5,-2) 表示数 阅读全文
posted @ 2012-09-13 10:47 jameshappy 阅读(339) 评论(0) 推荐(0) 编辑
摘要: 因为Oracle的SQL语句不能过长,大约4K限制,所以如果保存时Clob字段的内容过长的话会导致保存出错,提示"ORA-01704:文字字符串过长 "解决方案是带参数的update语句 strSql = "update web_goods set producthtml= :output where productid='"+strProductid+"'"; OracleParameter[] ps=new OracleParameter[1];ps[0] = new OracleParameter();ps[0] 阅读全文
posted @ 2012-09-13 10:44 jameshappy 阅读(4955) 评论(0) 推荐(0) 编辑
  2012年9月6日
摘要: create or replace procedure proc_SmsSendQueue as tmpMobilePhone varchar2(50); tmpSendcontent NVARCHAR2(100); tmpPhoneType CHAR(2); tmpSmsType VARCHAR2(16); tmpPriority Number(1); tmpEnterTime Date; tmpSendFlag Char(1); tmpSendCount Number(1); tmpCreatedby Number(8); tmpCreatedon Date; tmpLastupdate. 阅读全文
posted @ 2012-09-06 14:28 jameshappy 阅读(3007) 评论(0) 推荐(0) 编辑
  2012年5月23日
摘要: 1.where 不能放在GROUP BY 后面2.HAVING 是跟GROUP BY 连在一起用的,放在GROUP BY 后面,此时的作用相当于WHERE3.WHERE 后面的条件中不能有聚集函数,比如SUM(),AVG()等,而HAVING 可以 Where和Having都是对查询结果的一种筛选,说的书面点就是设定条件的语句。下面分别说明其用法和异同点。注:本文使用字段为oracle数据库中默认用户scott下面的emp表,sal代表员工工资,deptno代表部门编号。一、聚合函数 说明前我们先了解下聚合函数:聚合函数有时候也叫统计函数,它们的作用通常是对一组数据的统计,比如说求最大值,最小 阅读全文
posted @ 2012-05-23 17:01 jameshappy 阅读(62398) 评论(4) 推荐(4) 编辑
摘要: select * from (select * from tablename order by columnname desc) where rownum <=10 阅读全文
posted @ 2012-05-23 16:52 jameshappy 阅读(29346) 评论(2) 推荐(2) 编辑
  2012年4月13日
摘要: display:none和visible:hidden都能把网页上某个元素隐藏起来,但两者有区别:display:none ---不为被隐藏的对象保留其物理空间,即该对象在页面上彻底消失,通俗来说就是看不见也摸不到。visible:hidden--- 使对象在网页上不可见,但该对象在网页上所占的空间没有改变,通俗来说就是看不见但摸得到。例子:<html><head><title>display:none和visible:hidden的区别</title></head><body ><span style=" 阅读全文
posted @ 2012-04-13 10:54 jameshappy 阅读(244) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 10 11 12 ··· 14 下一页