上一页 1 ··· 89 90 91 92 93 94 95 96 97 ··· 106 下一页
摘要: --SQL Server 2000-----Calendar Table Geovin Du 涂聚文declare @start datetime,@end datetimeset @start = '2006-01-01'set @end = '2006-05-02'declare @no_of_Days intset @no_of_days = datediff(dd,@start,@end) + 1set rowcount @no_of_daysselect identity(int,0,1) as dy into #temp from sysobject 阅读全文
posted @ 2011-08-18 12:33 ®Geovin Du Dream Park™ 阅读(398) 评论(0) 推荐(0) 编辑
摘要: --返回第幾周DECLARE @Dt datetimeSELECT @Dt='2008-02-21'SELECT DATEPART( wk, @Dt)SELECT DATEPART( wk, GETDATE())SELECT DATEPART(weekday, GETDATE())SELECT * FROM WorkAttendanceReportSELECT [dbo].[GetWeekName] (WorkAttendanceDatetime) FROM WorkAttendanceReport---WorkAttendanceDatetimedeclare @Date s 阅读全文
posted @ 2011-08-15 18:42 ®Geovin Du Dream Park™ 阅读(2589) 评论(3) 推荐(0) 编辑
摘要: ---得到遲到多少時間或沒有遲到 Geovin Du 塗聚文declare cursor_select cursor for select WorkingHoursTime,WorkingHoursUidKey FROM WorkingHoursSetdeclare @ntime smalldatetime,@uidkey Uniqueidentifier,@timeint int,@empoyee Uniqueidentifier,@WorkAttendanceUid Uniqueidentifier--set @uidkey='E0ABDEC2-4BC9-49CB-85EE-E6E 阅读全文
posted @ 2011-08-10 12:37 ®Geovin Du Dream Park™ 阅读(857) 评论(0) 推荐(0) 编辑
摘要: ---會計記賬 Debit-Credit BookkeepingCREATE TABLE #geovindu ( Account VARCHAR(20), --賬號 [Date] DATETIME, --時間 Debit DECIMAL(9,2), --借入 Credit DECIMAL(9,2) --貸出) GOINSERT INTO #geovindu VALUES ('10139', '2007-08-31', 2025.91, 0.0) INSERT INTO #geovindu VALUES ('10139', '2007-08 阅读全文
posted @ 2011-07-23 12:19 ®Geovin Du Dream Park™ 阅读(425) 评论(0) 推荐(0) 编辑
摘要: ---SQL SERVER 2000 遍历父子关系數據表(二叉树)获得所有子节点 所有父节点及节点层数函数---Geovin Du 涂聚文--建立測試環境Create Table GeovinDu([ID] Int, fatherID Int, [Name] Varchar(10))Insert A Select 1, 0, '中国'Union All Select 2, 1, '广东'Union All Select 3, 1, '北京'Union All Select 4, 2, '深圳特区'Union All Select 阅读全文
posted @ 2011-07-12 16:12 ®Geovin Du Dream Park™ 阅读(1005) 评论(0) 推荐(0) 编辑
摘要: --sql server 2005 输出表的函數用法--Geovin Du 塗聚文 --締友計算機信息技術有限公司create function EmailParse (@email varchar(1000))returns @t table (UserName varchar(20), Domain varchar(20))asbegin declare @i int select @i = charindex('@', @email,1); if (@i > 1) insert into @t values (left(@email,@i-1), substring 阅读全文
posted @ 2011-07-08 15:58 ®Geovin Du Dream Park™ 阅读(355) 评论(0) 推荐(0) 编辑
摘要: --SQL server 2005 表中某一字段的所有值逗号分开的列表Geovin Du 塗聚文select * from Production.Productdeclare @names varchar(50)set @names=''select @names=@names+s.Name+' , 'from Production.Product sorder by s.Nameselect @namesgo--sql server 2000 如何逐条读出表中某一字段的所有值 Geovin Du 塗聚文declare @allstring varchar(80 阅读全文
posted @ 2011-07-08 08:37 ®Geovin Du Dream Park™ 阅读(401) 评论(0) 推荐(0) 编辑
摘要: http://jtoday.codeplex.com/jQuery jToday Plugin http://blog.donavon.com/2009/09/jquery-jtoday-plugin.htmljToday.js code:// jToday a simple jQuery date display plugin by Donavon West// Copyright 2009 Donavon West. All rights reserved(function($, document) {//--------------------$.fn.jToday = function 阅读全文
posted @ 2011-07-06 19:18 ®Geovin Du Dream Park™ 阅读(285) 评论(0) 推荐(0) 编辑
摘要: SQL Server 2000 http://msdn.microsoft.com/en-us/library/Aa223952http://msdn.microsoft.com/en-us/library/aa902644(SQL.80).aspxhttp://msdn.microsoft.com/en-us/library/aa902644(SQL.80).aspx#intlfeaturesinsqlserver2000_usingadpformatSQL Server 2005 http://msdn.microsoft.com/zh-cn/library/ms188688(v=sql. 阅读全文
posted @ 2011-07-04 18:26 ®Geovin Du Dream Park™ 阅读(345) 评论(0) 推荐(0) 编辑
摘要: /*****************************************---Geovin Du 塗聚文 締友計算機信息技術有限公司---公司集團有親屬員工顯示介紹人的姓名。一個表中的兩個外鍵是來自於同一個表*****************************************/--員工表IF EXISTS (select * from sysobjects where id = object_id(N'[dbo].[Employeetest]') and OBJECTPROPERTY(id, N'IsUserTable') = 1) D 阅读全文
posted @ 2011-07-01 11:19 ®Geovin Du Dream Park™ 阅读(1793) 评论(0) 推荐(0) 编辑
上一页 1 ··· 89 90 91 92 93 94 95 96 97 ··· 106 下一页