摘要: 1.用java.util.Calender来实现 Calendar calendar=Calendar.getInstance(); calendar.setTime(new Date()); System.out.println(calendar.get(Calendar.DAY_OF_MONTH));//今天的日期 calendar.set(Calendar.DAY_OF_MONTH,calendar.get(Calendar.DAY_OF_MONTH)+1);//让日期加1 System.out.println(calendar.get(Calendar.DATE));//加1之后... 阅读全文
posted @ 2012-10-23 12:51 冰镇橘子汽水 阅读(2280) 评论(0) 推荐(0)
摘要: linux下解压,打包 命令.tar 解包:tar xvf FileName.tar打包:tar cvf FileName.tar DirName(注:tar是打包,不是压缩!) .gz 解压1:gunzip FileName.gz解压2:gzip -d FileName.gz压缩:gzip FileName.tar.gz 和 .tgz 解压:tar zxvf FileName.tar.gz压缩:tar zcvf FileName.tar.gz DirName.bz2 解压1:bzip2 -d FileName.bz2解压2:bunzip2 FileName.bz2压缩: bzip2 -z F 阅读全文
posted @ 2012-10-17 00:24 冰镇橘子汽水 阅读(273) 评论(0) 推荐(0)
摘要: Oracle——distinct的用法distinct这个关键字来过滤掉多余的重复记录只保留一条,但往往只用 它来返回不重复记录的条数,而不是用它来返回不重记录的所有值。其原因是distinct只有用二重循环查询来解决,而这样对于一个数据量非常大的站来说,无疑是会直接影响到效率的。下面先来看看例子:table表字段1 字段2 id name 1 a 2 b 3 c 4 c 5 b库结构大概这样,这只是一个简单的例子,实际情况会复杂得多。比如我想用一条语句查询得到name不重复的所有数据,那就必须使用distinct去掉多余的重复记录。select distinct name from tabl 阅读全文
posted @ 2012-10-14 19:52 冰镇橘子汽水 阅读(299) 评论(0) 推荐(0)
摘要: 下面方法中有Excel格式的生成,以及下载写法。import jxl.Workbook;import jxl.format.Border;import jxl.format.BorderLineStyle;import jxl.format.Colour;import jxl.format.UnderlineStyle;import jxl.write.Label;import jxl.write.WritableCellFormat;import jxl.write.WritableFont;import jxl.write.WritableSheet;import jxl.write.Wr 阅读全文
posted @ 2012-10-08 10:40 冰镇橘子汽水 阅读(2114) 评论(0) 推荐(0)
摘要: <%@page import="com.taiji.waf.daxing.wsgl.getvalue.GetSelectvalue"%><%@ taglib prefix="s" uri="/struts-tags" %><%@ page contentType="text/html; charset=utf-8"%><%@ include file="/wafplatform/include.jsp" %><%@ page import=& 阅读全文
posted @ 2012-10-08 10:30 冰镇橘子汽水 阅读(1145) 评论(0) 推荐(0)
摘要: 给注册表中写入内容的页面,里面有具体的js代码。<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html> <head> <title>bb.html</title> <meta http-equiv="keywords" content="keyword1,keyword2,keyword3"> <meta http-equiv="description" 阅读全文
posted @ 2012-10-08 10:11 冰镇橘子汽水 阅读(271) 评论(0) 推荐(0)
摘要: sudo !!以 root 帐户执行上一条命令。python -m SimpleHTTPServer利用 Python 搭建一个简单的 Web 服务器,可通过 http://$HOSTNAME:8000 访问。:w !sudo tee %在 Vim 中无需权限保存编辑的文件。cd -更改到上一次访问的目录。^foo^bar将上一条命令中的 foo 替换为 bar,并执行。cp filename{,.bak}快速备份或复制文件。mtr google.comtraceroute + ping。!whatever:p搜索命令历史,但不执行。$ssh-copy-id user@host将 ssh ke 阅读全文
posted @ 2012-07-26 20:17 冰镇橘子汽水 阅读(157) 评论(0) 推荐(0)
摘要: <ul><div id="clock"></div> <script> function changeClock() { var d = new Date(); document.getElementById("clock").innerHTML = d.getFullYear() + "-" + (d.getMonth() + 1) + "-" + d.getDate() + " " + d.getHours() + ":" 阅读全文
posted @ 2012-07-26 12:19 冰镇橘子汽水 阅读(191) 评论(0) 推荐(0)
摘要: <script>function SetWinHeight(obj) { var win = obj; if (document.getElementById) { if (win && !window.opera) { if (win.contentDocument&& win.contentDocument.body.offsetHeight) win.height = win.contentDocument.body.offsetHeight; else if (win.Document ... 阅读全文
posted @ 2012-07-04 10:51 冰镇橘子汽水 阅读(362) 评论(0) 推荐(0)
摘要: //oracle.sql.Clob类型转换成String类型 public String ClobToString(Clob clob) { String reString = ""; Reader is = null; try { is = clob.getCharacterStream(); } catch (SQLException e) { // TODO Auto-generated catch block e.printStackTrace(); ... 阅读全文
posted @ 2012-06-28 14:24 冰镇橘子汽水 阅读(19907) 评论(0) 推荐(1)