惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

L
LINUX DO - 热门话题
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
K
Kaspersky official blog
Google Online Security Blog
Google Online Security Blog
Simon Willison's Weblog
Simon Willison's Weblog
Hacker News - Newest:
Hacker News - Newest: "LLM"
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
P
Privacy International News Feed
D
Docker
Cisco Talos Blog
Cisco Talos Blog
Spread Privacy
Spread Privacy
Jina AI
Jina AI
Last Week in AI
Last Week in AI
The Last Watchdog
The Last Watchdog
WordPress大学
WordPress大学
Project Zero
Project Zero
小众软件
小众软件
V
V2EX
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
L
Lohrmann on Cybersecurity
T
Troy Hunt's Blog
www.infosecurity-magazine.com
www.infosecurity-magazine.com
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
P
Privacy & Cybersecurity Law Blog
AWS News Blog
AWS News Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
W
WeLiveSecurity
V
Vulnerabilities – Threatpost
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
爱范儿
爱范儿
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Apple Machine Learning Research
Apple Machine Learning Research
月光博客
月光博客
博客园 - 三生石上(FineUI控件)
Cloudbric
Cloudbric
罗磊的独立博客
TaoSecurity Blog
TaoSecurity Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Google DeepMind News
Google DeepMind News
雷峰网
雷峰网
IT之家
IT之家
A
Arctic Wolf
The Hacker News
The Hacker News
T
Tailwind CSS Blog
Know Your Adversary
Know Your Adversary
博客园 - 司徒正美
腾讯CDC
S
SegmentFault 最新的问题
P
Palo Alto Networks Blog
NISL@THU
NISL@THU

博客园 - Vincent

reCaptcha 在UpdatePanel 和 ModalPopup中的使用 - Vincent Invalid character in a Base-64 string System.ArgumentOutOfRangeException at System.Web.HttpCachePolicy.UtcSetLastModified (DateTime utcDate) Fabulous Adventures In Coding Microsoft will end OEM and shrink-wrapped sales of Windows XP on June 30, 2008 - Vincent My AutoCompleteExtender Windows Live Writer GRI-MindHarbor软件公司 单表继承 (Single Table Inheritance) 很久没有写blog了. Base64 MD5加密 信用卡是超前消费的一种手段 vs.net2003无法打开*.xsd文件的解决方法 针对MS Project 2003 的开发 Test Your Knowledge of Microsoft Visual Studio .NET page event Microsoft Office InfoPath 2003 Toolkit for Visual Studio .NET 在Code-Behind中操作WebUserControl
写给yzx110的一个实例,仅作参考!
Vincent · 2005-11-29 · via 博客园 - Vincent

 1        public bool DBCommandWrapper(string commandText, OracleParameterCollection Parameters) {
 2            try {
 3                this.dbCommand = new OracleCommand(commandText, (OracleConnection) this.dbConnection);
 4
 5                this.dbConnection.Open();
 6
 7
 8
 9
10                foreach (OracleParameter op in Parameters) {
11                    if (op.OracleType ==OracleType.Char ) {
12                        this.dbCommand.Parameters.Add(op.ParameterName, OracleType.Char).Value = Convert.ToByte(op.Value);
13                    }

14                    else {
15                        if (op.OracleType == OracleType.VarChar) {
16                            op.Value = op.Value==null ? OracleString.Null : op.Value;
17                            this.dbCommand.Parameters.Add(op.ParameterName, op.DbType).Value = op.Value;
18                        }

19                        else {
20                            this.dbCommand.Parameters.Add(op.ParameterName, op.OracleType).Value = op.Value;
21                        }

22                    }

23                }

24
25                this.dbCommand.ExecuteNonQuery();
26
27
28
29                return true;
30            }

31            catch (Exception ex) {
32
33                sb.Append("Error Message: ");
38                sb.Append(ex.Message);
39                sb.Append("\r\n");
40                return false;
41            }

42            finally {
43                this.dbCommand.Parameters.Clear();
44                this.dbConnection.Close();
45            }

46
47        }

知识共享许可协议
本作品采用知识共享署名 2.5 中国大陆许可协议进行许可。必须保留本文的署名以及原文链接.

posted @ 2005-11-29 00:47  Vincent  阅读(687)  评论(0)    收藏  举报

刷新页面返回顶部