上一页 1 ··· 140 141 142 143 144 145 146 147 148 ··· 162 下一页

2007年3月17日

一种BOM所用的Function...

摘要: ---问题---create table BOM(CODE varchar(4),C_CODE varchar(4),NUM int)insert into BOM select 'A','B',2insert into BOM select 'A','C',1insert into BOM se... 阅读全文

posted @ 2007-03-17 10:25 封起De日子 阅读(131) 评论(0) 推荐(0) 编辑

一段取值的sql...(charindex的应用)

摘要: ---问题---/*表test字段中field的值如下:aa,cd;ttttdd,pp;qq;ttd pptt,qqq;ttt;1oo;tt 希望把字段值都更新一下,取第一个","号前的值,如果没有","号则取";"前的值,如果值为空就还是为空,最终的值变成如下:aattddqq ppttoo*/... 阅读全文

posted @ 2007-03-17 10:21 封起De日子 阅读(151) 评论(0) 推荐(0) 编辑

Sql server identity字段的重新定位...

摘要: ---问题---/*create table t_t1 (id int identity(1,1),name varchar(10)) insert into t_t1 select 'xx1'union all select 'xx1'union all select 'xx1'union al... 阅读全文

posted @ 2007-03-17 10:16 封起De日子 阅读(110) 评论(0) 推荐(0) 编辑

Sql server 日期型与数值型的转换....

摘要: ---问题---/*现在遇到一个问题: 数据库是sql server2000,前台录入的是时间,但是数据库中存的确是int型,如果我要按照日期查找(例如找2007-3-12到2007-3-24的数据),我应该如何写sql语句. 假设表名为test,保存日期的字段名为open_date.*/ dec... 阅读全文

posted @ 2007-03-17 10:14 封起De日子 阅读(4208) 评论(0) 推荐(0) 编辑

Sql Server Some Question --Case...Whne...(2)

摘要: ----问题----/*在SQL server中,表为:create table tt1(id int identity(1,1),T_key varchar(10),T_value varchar(10),T_remark varchar(20))goinsert tt1 values('key... 阅读全文

posted @ 2007-03-17 10:12 封起De日子 阅读(104) 评论(0) 推荐(0) 编辑

Sql Server Some Question --Select Interzone(区间的) Data

摘要: ----问题----查找第10 - 20 的记录declare @tb_1 table(id int identity(1,1), name varchar(10)) declare @i intset @i=0 while @i<20begininsert into @tb_1 select '... 阅读全文

posted @ 2007-03-17 09:28 封起De日子 阅读(94) 评论(0) 推荐(0) 编辑

Sql Server Some Question --Case...Whne...(1)

摘要: --- 问题----1)给出你的问题的SQL脚本和样例数据,如:/*create table t( year int not null, --年度 s1 int, -- 一季度销售额 s2 int, -- 二季度销售额 s3 int, -- 三季度销售额 s4 int -- 四季度销售额 ) in... 阅读全文

posted @ 2007-03-17 09:23 封起De日子 阅读(113) 评论(0) 推荐(0) 编辑

2007年3月11日

JS实现从照片中裁切自已的肖像

摘要: 代码如下: [Ctrl+A 全选 提示:你可先修改部分代码,再点运行代码] 阅读全文

posted @ 2007-03-11 11:27 封起De日子 阅读(133) 评论(0) 推荐(0) 编辑

SQL中CONVERT转化函数的用法

摘要: 格式:CONVERT(data_type,expression[,style])说明:此样式一般在时间类型(datetime,smalldatetime)与字符串类型(nchar,nvarchar,char,varchar)相互转换的时候才用到.例子:SELECT CONVERT(varchar(... 阅读全文

posted @ 2007-03-11 11:23 封起De日子 阅读(186) 评论(0) 推荐(0) 编辑

学习MDX的15个例子

摘要: http://www.windowsitpro.com/SQLServer/Article/ArticleID/22994/22994.html The most frequent request that I receive from readers is for more info... 阅读全文

posted @ 2007-03-11 11:06 封起De日子 阅读(218) 评论(0) 推荐(0) 编辑

上一页 1 ··· 140 141 142 143 144 145 146 147 148 ··· 162 下一页

导航