01 2008 档案

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 飞天舞者 阅读(161) 评论(0) 推荐(0) 编辑

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 飞天舞者 阅读(221) 评论(0) 推荐(0) 编辑

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 飞天舞者 阅读(275) 评论(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 飞天舞者 阅读(217) 评论(0) 推荐(0) 编辑

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

posted @ 2008-01-17 09:35 飞天舞者 阅读(386) 评论(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 飞天舞者 阅读(184) 评论(0) 推荐(0) 编辑

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 飞天舞者 阅读(278) 评论(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 飞天舞者 阅读(247) 评论(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 飞天舞者 阅读(303) 评论(0) 推荐(0) 编辑

get all table's information concerned
摘要:1 get all columnname select [name] from syscolums where id=object_id('tablename) 2 get all tables select [name] from SysObjects where type='U' 3 get all datatype of system select [xtype],[name] from ... 阅读全文

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

create procedure grammar
摘要:Create procedure pre_name @variable list as pro_doby Eg. Create procedure sp_GetUserInformation @userid char(15)=’00001’, @username char(2) output, //which means username is outout @addr... 阅读全文

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

tips for private constructor
摘要:when one class just declares its private constructor , then it’s not allowed to derive another class from which and also create an instance of which. Therefore, private construtor class usually o... 阅读全文

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

all Key Word of C#
摘要:Abstract base bool break box unboxing byte case Catch char checked class const continue Demical default delegate do double else ... 阅读全文

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

How to Identify User&Password of DataBase safely in SQL statement?
摘要:Problem description: for many developer, they don't care much about Passcode identity. when Logining into the database server ,they just write like this: sql="select * from user where username='"+... 阅读全文

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

Edit(Update,Cancel) ,Delete in DataList webcontrol
摘要:1 we must set different template of the datalist object as diffirent appearance, such as itemplate,editplate,headertemplate,footertemplate. in edit template, Update function should have the Updat... 阅读全文

posted @ 2008-01-06 13:03 飞天舞者 阅读(527) 评论(0) 推荐(0) 编辑

Use SqlDataAdapter to update database, but SqlCommandBuilder required
摘要:SqlDataAdapter da = new SqlDataAdapter(); SqlCommand cmd = new SqlCommand("select * from t_upload", conn); da.SelectCommand = cmd; SqlCommandBui... 阅读全文

posted @ 2008-01-04 21:44 飞天舞者 阅读(183) 评论(0) 推荐(0) 编辑

File Reader sample
摘要:private void GetFileContents(String FileName) { try { FileInfo inf = new FileInfo(FileName); StreamReader rd = new StreamReader(inf.OpenRead()); ... 阅读全文

posted @ 2008-01-04 21:41 飞天舞者 阅读(164) 评论(0) 推荐(0) 编辑

IO-->File and Directory class
摘要:The class to process the file and directory mainly include Directory, DirectoryInfo, File, FileInfo Directory : create, move, rename, delete directory with static method . if you will use a directo... 阅读全文

posted @ 2008-01-04 21:41 飞天舞者 阅读(179) 评论(0) 推荐(0) 编辑

operate XML file(update,delete)
摘要:4. update value in XML file XmlNodeList nodeList=xmlDoc.SelectSingleNode("bookstore").ChildNodes;//获取bookstore节点的所有子节点 foreach(XmlNode xn in nodeList)//遍历所有子节点 { XmlElement xe=(XmlElement)xn... 阅读全文

posted @ 2008-01-04 21:39 飞天舞者 阅读(273) 评论(0) 推荐(0) 编辑

operate XML file (Open,Insert)
摘要:1. Some specific name: XmlDocument XmlNodeList XmlNode XmlElement The whole architecture and relation among them is following Attentions:selectsinglenodelist(”users”),用于获取users下面的所有直接子节点。这个方... 阅读全文

posted @ 2008-01-04 21:38 飞天舞者 阅读(358) 评论(0) 推荐(0) 编辑

upload file to server
摘要:Way 1: UpLoadFile webcontrol can finish it easy FileUpLoad ful_load =new FileUpLoad(); //FileUpLoad is a kind of control ….. Set the upload file name; ful_load.SaveAs(Server.MapPath(ful_load.Fil... 阅读全文

posted @ 2008-01-04 21:34 飞天舞者 阅读(461) 评论(0) 推荐(0) 编辑

save cookies and get cookies in system using asp.net
摘要:1. use Response.cookies[“cookiesname”][“keyname”] to save cookies 2. use Request.cookies[“cookiesname”][“keyname”] to get cookies; Eg. Save cookies codingl Response.Cookies["userinfo"]["username"] = ... 阅读全文

posted @ 2008-01-04 21:33 飞天舞者 阅读(248) 评论(0) 推荐(0) 编辑

Send mail with attachment in asp.net
摘要://send mail MailMessage message = new MailMessage(); message.To = this.txtEmail.Text.Trim(); message.From = this.txtMyemail.Text.Trim(); message.Body = this.txtBody.Text.Trim(); message... 阅读全文

posted @ 2008-01-04 21:32 飞天舞者 阅读(236) 评论(0) 推荐(0) 编辑

select multi option in checkbox group in one time
摘要:Such as: there is a checkbox group in a datalist named datalist1. we need to catch the name selected through pressing the button2. the codes is following. protected void Button2_Click(object sender, ... 阅读全文

posted @ 2008-01-04 21:29 飞天舞者 阅读(328) 评论(0) 推荐(0) 编辑

the differences between DataGrid and DataList in HTML View
摘要:1.datagrid The datagrid’s label of vs.net is 2.datalist > 阅读全文

posted @ 2008-01-04 21:28 飞天舞者 阅读(235) 评论(0) 推荐(0) 编辑

add custom attribute to standard windows controls
摘要:Eg.there is a button name hrg_button, when we press the button,it should popup a prompt window; We should code the following: Hrg_button.addtribute.add(“onclick”,”confirm(‘are you sure?’)”); 阅读全文

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

Connection string for oledb and sql
摘要:First case:oledb OleDbConnection conn; Conn.connectionstring=”microsoft.Jet.Oledb.4.0;data source=test.mdb;Persist Security Info=false”; Second case: SqlConnection conn; Con.connenctstring=”datasource... 阅读全文

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

AJAX Asynchronous JavaScript and XML
摘要:ajax architecture 1.Intitial XMLHttpRequest object and send the Request; 2. assign the process function for the request; 3.send out the http request; 4.process the return result from s... 阅读全文

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

1.the response.request,server,session in a self-create class
摘要:class A { protected HttpSessionState Session; protected HttpServerUtility Server; protected HttpRequest Request; procteted HtpResponse Response; public A(object parent) { ... 阅读全文

posted @ 2008-01-04 08:19 飞天舞者 阅读(218) 评论(0) 推荐(0) 编辑

已经感冒好长一段时间了 不过今天我的新blog开张
摘要:感冒了快一个礼拜了。本来很相信自己身体的抵抗能力的,所以故意不去医院。现在看来不能和自己过去不了。前段时间在Intel有点闲。突然间来了这么多事情,真是有点措手不及了。哈哈,好了。我的新blog开张了。现在开始放鞭炮了,请大家散开,以免误伤:) 阅读全文

posted @ 2008-01-03 18:43 飞天舞者 阅读(178) 评论(1) 推荐(0) 编辑

导航

< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5
For more information about me, feel free email to me winston.he@hotmail.com
点击右上角即可分享
微信分享提示