PHP中使用存储过程
来源:互联网 发布:淘宝家具类目如何操作 编辑:程序博客网 时间:2024/05/16 12:20
下面是一个简单的存贮过程
CREATE PROCEDURE [sp_mystoreprocedure] AS
select Host,User,Password from user
<?
define ("OLEDB_CONNECTION_STRING",
"Provider=SQLOLEDB; Data Source=zzb; Initial Catalog=Northwind; User ID=sa; Password=");
$dbc = new COM("ADODB.Connection");
$dbc->Open(OLEDB_CONNECTION_STRING);
$command = "sp_mystoreprocedure";
$rs = $dbc->Execute($command); // Recordset
$i = 0;
echo '<table cellSpacing="1" cellPadding="3" width="600" align="center" bgColor="#000000" border="0">
<tr vAlign="bottom" bgColor="#9999cc">
<th>Directive</th>
<th>Local Value</th>
<th>Master Value</th>
</tr>';
while (!$rs->EOF) {
$i += 1;
$fld0 = $rs->Fields(0);
$fld1 = $rs->Fields(1);
$fld2 = $rs->Fields(2);
print '<tr vAlign="baseline" bgColor="#cccccc">
<td bgColor="#ccccff"><b>';
print $fld0->value;
print '</b><br></td>
<td align="middle">';
print $fld1->value;
print '</td><td align="middle">';
print $fld2->value;
print '</td></tr>';
$rs->MoveNext();
}
print '</TABLE>';
$rs->Close();
?>
- PHP中使用存储过程
- php 存储过程使用
- PHP使用存储过程
- Php mysql 存储过程使用
- ASP中使用存储过程
- ASP中使用存储过程
- VC中使用存储过程
- VC中使用存储过程
- java中使用存储过程
- 存储过程中使用事务
- asp中使用存储过程
- JDBC中使用存储过程
- mysql 中使用存储过程
- mysql 中使用存储过程
- mysql 中使用存储过程
- 程序中使用存储过程
- hibernate中使用存储过程
- C#中使用存储过程
- ###################2006.7.26########关于引用和指针的心得##############
- 广州第4届车展(香车)
- 各款adsl(猫)默认密码
- demo简介
- JUnit单元测试感悟
- PHP中使用存储过程
- 我对于“Tag”的理解
- 陈一舟、蔡文胜、周鸿祎、李彦宏频频出手 四大家族争购“流氓软件”
- 让人郁闷的org.hibernate.MappingException: duplicate import......
- UBUNTU下安装oracle 10g,并连接到ORACLE
- 文档管理与文档规范
- Spring AOP实际应用一例
- Spring AOP框架
- 如何规划职业发展道路——给软件从业人员的建议