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

推荐订阅源

A
About on SuperTechFans
Cloudbric
Cloudbric
C
CERT Recently Published Vulnerability Notes
G
GRAHAM CLULEY
V
Vulnerabilities – Threatpost
C
Cisco Blogs
T
Tenable Blog
P
Privacy International News Feed
T
The Exploit Database - CXSecurity.com
I
Intezer
AWS News Blog
AWS News Blog
IT之家
IT之家
博客园 - 司徒正美
C
Cybersecurity and Infrastructure Security Agency CISA
博客园 - 【当耐特】
The Hacker News
The Hacker News
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
Spread Privacy
Spread Privacy
S
SegmentFault 最新的问题
博客园 - Franky
人人都是产品经理
人人都是产品经理
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
V
Visual Studio Blog
C
CXSECURITY Database RSS Feed - CXSecurity.com
H
Hacker News: Front Page
Latest news
Latest news
Scott Helme
Scott Helme
腾讯CDC
宝玉的分享
宝玉的分享
大猫的无限游戏
大猫的无限游戏
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
A
Arctic Wolf
S
Securelist
雷峰网
雷峰网
The GitHub Blog
The GitHub Blog
Project Zero
Project Zero
Google DeepMind News
Google DeepMind News
P
Palo Alto Networks Blog
F
Fortinet All Blogs
Schneier on Security
Schneier on Security
云风的 BLOG
云风的 BLOG
Security Archives - TechRepublic
Security Archives - TechRepublic
The Last Watchdog
The Last Watchdog
WordPress大学
WordPress大学
MongoDB | Blog
MongoDB | Blog
L
LINUX DO - 最新话题
S
Schneier on Security
NISL@THU
NISL@THU
Jina AI
Jina AI
M
MIT News - Artificial intelligence

博客园 - loway

必须掌握的八个DOS命令 [转] asp免费源代码 ASP 中 Split 函数的实例 - loway ASP:Recordset对象方法 ASP错误编码大全 实用网页代码 - loway - 博客园 翻页的存储过程 纯ASP上传图像文件到数据库的最佳例子 - loway - 博客园 禁止右键、选择、粘贴、shift、ctrl、alt..... - loway - 博客园 弹出式说明窗口---JavaScript的使用 asp之fso操作大全代码奉送 JS的正则表达式 在ASP中轻松实现记录集分页显示 ASP开发中存储过程应用全接触 数据库设计 正则表达式语法 水晶报表参数编程示例代码 经典水晶报表设计——国际销售合同! .NET环境下水晶报表使用总结
ASP各种存储过程使用指南 - loway - 博客园
loway · 2006-05-15 · via 博客园 - loway

<%@ Language=VBScript %>
<%

'---开始链接数据库
Dim strConnString
strConnString = "driver={SQL Server};server=songhp;uid=sa;pwd=;database=XVZDemo"
set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open strConnstring
'---结束链接数据库

'---开始为输入参数赋值
Dim SelectSql , SelectRs
Dim SelectID , SelectName , SelectReturn
SelectSql = "Select Max(CompanyID) From Dim_Company"
Set SelectRs = Conn.Execute(SelectSql)
SelectID = SelectRs(0)
'---结束为输入参数赋值

Dim TiggerType
TiggerType = 3

Set Cmd = Server.CreateObject("ADODB.Command") 
Set Cmd.ActiveConnection = Conn
Cmd.CommandType = 4   '---声明此过程为存储过程

If TiggerType = 1 then
 
 '---开始一个输入参数的存储过程调用
 Cmd.CommandText = "TransCompany1"
 
 Set CmdParam = Cmd.CreateParameter("@TransID",3,1)
 Cmd.Parameters.Append CmdParam
 Cmd("@TransID") = SelectID
 Cmd.Execute
 '---结束一个输入参数的存储过程调用
 
Elseif TiggerType = 2 then

 '---开始一个输入参数,一个输出参数的存储过程调用
 Cmd.CommandText = "TransCompany2"
 
 Set CmdParamID = Cmd.CreateParameter("@TransID",3,1)
 Cmd.Parameters.Append CmdParamID
 Cmd("@TransID") = SelectID
 Set CmdParamName = Cmd.CreateParameter("@TransName",202,2,50)
 Cmd.Parameters.Append CmdParamName
 Cmd.Execute
 SelectName = Cmd("@TransName")
 '---结束一个输入参数,一个输出参数的存储过程调用

Elseif TiggerType = 3 then

 '---开始一个输入参数,一个输出参数,一个返回值的存储过程调用
 Cmd.CommandText = "TransCompany3"
 Set CmdParamReturn = Cmd.CreateParameter("Return_Value",3,4)
 Cmd.Parameters.Append CmdParamReturn
 Set CmdParamID = Cmd.CreateParameter("@TransID",3,1)
 Cmd.Parameters.Append CmdParamID
 Cmd("@TransID") = SelectID
 Set CmdParamName = Cmd.CreateParameter("@TransName",202,2,50)
 Cmd.Parameters.Append CmdParamName
 
 Cmd.Execute
 SelectName = Cmd("@TransName")
 SelectReturn = Cmd("Return_Value")
 '---结束一个输入参数,一个输出参数,一个返回值的存储过程调用

End if

Conn.Close
Set Conn = Nothing
Set Cmd = Nothing
Set CmdParamID = Nothing
Set CmdParamname = Nothing
Set CmdParamReturn = Nothing
%>