2008年2月20日

C++的四种cast操作符的区别

摘要: Q:什么是C风格转换?什么是static_cast, dynamic_cast 以及 reinterpret_cast?区别是什么?为什么要注意? A:转换的含义是通过改变一个变量的类型为别的类型从而改变该变量的表示方式。为了类型转换一个简单对象为另一个对象你会使用传统的类型转换操作符。比如,为了转换一个类型为doubole的浮点数的指针到整型: 代码: int i; double d; ... 阅读全文

posted @ 2008-02-20 10:51 飞天舞者 阅读(558) 评论(0) 推荐(0) 编辑

2008年1月25日

some tips about sys.objects table

摘要: all database objects are stored in sys.objects table. they can be classified as following type: U ==> normal table V ==> View S ==> System table P ==> Store Procedure ... for example, if we 'd like t... 阅读全文

posted @ 2008-01-25 14:37 飞天舞者 阅读(156) 评论(0) 推荐(0) 编辑

2008年1月22日

just some skills for SQL

摘要: 1 about the name regulation for table,store procedure,view .. normally, each different kind of object should be named with specific flag, such as table named as Tab_*, store procedure named ... 阅读全文

posted @ 2008-01-22 16:55 飞天舞者 阅读(217) 评论(0) 推荐(0) 编辑

2008年1月17日

execute sql query dynamically

摘要: eg: create proc pr_test @table varchar(128), @database varchar(128) as declare @str1 varchar(128) declare @str2 varchar(128) set @str2=' select * from '+@database+'.dbo.'+@table exec (@str1+@str2) 阅读全文

posted @ 2008-01-17 15:57 飞天舞者 阅读(273) 评论(0) 推荐(0) 编辑

insert/process multi-records without cursor

摘要: if object_id('Pr_ToSolver_ds_in_item_group_loc_period') is not null drop proc Pr_ToSolver_ds_in_item_group_loc_period create proc Pr_ToSolver_ds_in_item_group_loc_period as insert into ds_in_ite... 阅读全文

posted @ 2008-01-17 11:34 飞天舞者 阅读(213) 评论(0) 推荐(0) 编辑

今天参加了2008年intel PD site annual party

摘要: 今天是第一次参加intel pd site的年会。可能人比较多的缘故,所以看起来场面还是满大的,地点选在了世贸佘山一个什么酒店。节目基本都是恶搞类型的。不过那晚餐啊,还说什么五星级酒店,实在不敢恭维哦。最不爽的是喝了点小啤酒,结果在车上甚感不适,憋了一个多小时,苦萨我也 阅读全文

posted @ 2008-01-17 09:35 飞天舞者 阅读(385) 评论(1) 推荐(0) 编辑

how to judge if the temptable or normal table that you created exists

摘要: just as the following scripts shows: 1.temp table if exists (select * from sysobjects where objectproperty(object_id('TempTableName'),'istable') = 1) 2.normal table if object_id('tablename') i... 阅读全文

posted @ 2008-01-17 09:20 飞天舞者 阅读(179) 评论(0) 推荐(0) 编辑

2008年1月16日

simple =, join,left out join,right outer join, cross join

摘要: a. = eg. Select A.a B.b from A, B where A.a=B.a and A.c=’herengang’; under this condition, it only shows the data that A.a=B.a and A.c=”herengang”. Although it there is data wh... 阅读全文

posted @ 2008-01-16 11:18 飞天舞者 阅读(276) 评论(0) 推荐(0) 编辑

How to receive another procedure result in one procedure.

摘要: The grammar is following, eg: declare @result int exec @result=sp_userTest select @result //statements: sp_userTest is a procedure,which is following create procedure sp_userTest As Select * from aut... 阅读全文

posted @ 2008-01-16 11:13 飞天舞者 阅读(246) 评论(0) 推荐(0) 编辑

how to call the procedure in c# program

摘要: To call the procedure, it need the followng steps open the connection of database. open the commander , at the same time , we must set the command type be storeprocedure. Of course, opening the comman... 阅读全文

posted @ 2008-01-16 11:11 飞天舞者 阅读(298) 评论(0) 推荐(0) 编辑

导航

For more information about me, feel free email to me winston.he@hotmail.com