zoukankan      html  css  js  c++  java
  • 多步操作产生错误,请检查每一步的状态值

    需检查是否是以下这些情况:

    1.无主键

    2.字段允许为空

    3.字段类型不匹配

    4.字段是不是精度不够。

    5.ADO控件 CursorLocation的属性,默认值为“clUseClient”,应设为“clUseServer”。

    帮助文档资料如下:

    Use CursorLocation to indicate whether the cursors that use the connection object to connect to the ADO datastore use a client-side or server-side cursor library. CursorLocation only affects connections opened after the property is set. The default value for CursorLocation is clUseClient.

    A client-side cursor offers more flexibility. All data is retrieved to the local machine and then operated on there, allowing operations not normally supported by servers like sorting and resorting the data and additional filtering. SQL statements are executed at the server, so for statements that restrict the result set with a WHERE clause, only the reduced result set is retrieved to a local cursor.

    A server-side cursor offers less flexibility, but may be more advantageous (or necessary) for large result sets. Using a server-side cursor becomes necessary when the sheer size of a result set exceeds the available disk space that would be needed to create the client-side cursor. Also, many servers only support unidirectional cursors. This would preclude moving the record pointer in the dataset backward (even one record) through the result set.

    简单翻译一下:

    CursorLocation 是用来确认数据库连接对象是使用服务端还是客户端游标库的属性,默认值为clUseClient。

    客户端光标提供更多的灵活性,所有的数据是下载到本地后再进行操作,允许进行一些服务端不允许的操作,如排序、重置和过滤等等。SQL语句本身是在服务端执行,并且只返回WHERE子句限制下的结果集。

    服务端光标的灵活性较差,但是比较利于执行大数据量的操作。但如果返回的结果集超过了设定的磁盘缓冲空间就必须使用客户端光标了。而且很多数据库服务器只支持单向游标,这就意味着,你只能从头到尾遍历一次数据集(即使是一条记录)。

    来源:http://www.cnblogs.com/chinahbzm/articles/1268357.html

  • 相关阅读:
    MVC3基础嵌套总结
    List之Union(),Intersect(),Except() 亦可以说是数学中的并集,交集,差集
    sqlserver查询记录数某个区间内记录
    各语言的unix时间戳 【转】
    SQLserver删除某数据库中所有表
    C#日期格式转换大全
    【转】Linq之动态排序(字符传入)
    谈谈Equals和GetHashcode
    JS常用代码收集
    ROW_NUMBER()、RANK()、DENSE_RANK()、NTILE(N)
  • 原文地址:https://www.cnblogs.com/railgunman/p/1978497.html
Copyright © 2011-2022 走看看