declare @tm datetime set @tm = CONVERT(datetime,'2013-3-12')declare @days intselect @days = case when MONTH(@tm) in(1,3,5,7,8,10,12) then 31 when MONTH(@tm) in(4,6,9,11) then 30 when MONTH(@tm) =2 and YEAR(@tm)%4 !=0 then 28 when MONTH(@tm) =2 and YE
/// 当前月有多少天 /// </summary> /// <param name="y"></param> /// <param name="m"></param> /// <returns></returns> public static int HowMonthDay(int y, int m) { int mnext; int ynext; ) { mnext = m +
20130909 周一 oracle sql 开发指南 第7章 高级查询 1.层次化查询select level,ttt.*,sys_connect_by_path(ttt.col1,',') from ttt start with .. Connect by prior …因为先建立树,再进行where过滤的.在where中过滤和在cooonect by中过滤是不一样的. 2.rollup cube高级查询 select grouping(col1) .. From ttt group by
--DateTime 数字型 System.DateTime currentTime=new System.DateTime(); 取当前年月日时分秒 currentTime=System.DateTime.Now; 取当前年 int 年=currentTime.Year; 取当前月 int 月=currentTime.Month; 取当前日 int 日=currentTime.Day; 取当前时 int 时=currentTime.Hour; 取当前分
可以显示系统的静态时间和动态时间 1,静态时间 <script type="text/javascript"> var myDate = new Date(); document.write(myDate.toLocaleString()) </script> 静态时间显示 2,动态时间显示 <script> function show(){ var date = new Date(); //日期对象 var now = "";
js部分: <!--自动更新时间--><script>function show(){var date = new Date(); //日期对象var now = "";now = date.getFullYear()+"年"; //读英文就行了now = now + (date.getMonth()+1)+"月"; //取月的时候取的是当前月-1如果想取当前月+1就可以了now = now + date.getDate(
http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemCode=3605 Find the Marble Time Limit: 2 Seconds Memory Limit: 65536 KB Alice and Bob are playing a game. This game is played with several identical pots and one marble. When the game starts