基本的ADO模型

来源:互联网 发布:Mac古墓丽影手柄 编辑:程序博客网 时间:2024/06/05 10:19
<script type="text/javascript"><!--google_ad_client = "pub-2947489232296736";/* 728x15, 创建于 08-4-23MSDN */google_ad_slot = "3624277373";google_ad_width = 728;google_ad_height = 15;//--></script><script type="text/javascript"src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
<script type="text/javascript"><!--google_ad_client = "pub-2947489232296736";/* 160x600, 创建于 08-4-23MSDN */google_ad_slot = "4367022601";google_ad_width = 160;google_ad_height = 600;//--></script><script type="text/javascript"src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
基本ADO编程模型







ADO提供执行以下操作的方式:连接到数据源。同时,可确定对数据源的所有更改是否已成功或没有发生。

指定访问数据源的命令,同时可带变量参数,或优化执行。

执行命令。

如果这个命令使数据按表中的行的形式返回,则将这些行存储在易于检查、操作或更改的缓存中。

适当情况下,可使用缓存行的更改内容来更新数据源。

提供常规方法检测错误(通常由建立连接或执行命令造成)。
在典型情况下,需要在编程模型中采用所有这些步骤。但是,由于ADO有很强的灵活性,所以最后只需执行部分模块就能做一些有用的工作。例如:将数据从文件直接存储到缓存行,然后仅用ADO资源对数据进行检查。
<script type="text/javascript"><!--google_ad_client = "pub-2947489232296736";/* 728x15, 创建于 08-4-23MSDN */google_ad_slot = "3624277373";google_ad_width = 728;google_ad_height = 15;//--></script><script type="text/javascript"src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
<script type="text/javascript"><!--google_ad_client = "pub-2947489232296736";/* 160x600, 创建于 08-4-23MSDN */google_ad_slot = "4367022601";google_ad_width = 160;google_ad_height = 600;//--></script><script type="text/javascript"src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>