Max row size for Sybase
来源:互联网 发布:知鸟论文检测系统 编辑:程序博客网 时间:2024/06/06 18:29
数据库有max row sizex限制, 它的大小取决于 max page size, 而后者是在创建DB Server时指定的,它是Server-wide的,作用于DB Server下的所有数据库。 就Sybase 数据库而言, max row size 是1962byte, 而 max page size 是2048byte, 在Sybase version12 之前,max page size 只有2048byte 一种选择,而之后有了:2048 4096 8192 16384 四种选择,可以在创建DB Server 时指定,也可以之后通过Sybase Central 工具修改, 重启DB Server后生效, 而默认的为2048。 具体page size 与row size关系如下。
Page size
Maximum row length
Maximum column length
2K (2048 bytes)
1962
1948
4K (4096 bytes)
4010
3988
8K (8192 bytes)
8096
8058
16K (16384 bytes)
16298
16228
需要注意的是,当更新表时(update/insert),如果所有字段的值的长度大于了max row size, 执行就会失败,且向前端抛异常如下:com.sybase.jdbc2.jdbc.SybSQLException: Attempt to update or insert row failed because resultant row of size 2864 bytes is larger than the maximum size (1962 bytes) allowed for this table.
事实上,在创建存储过程时已有警告:
Warnings: --->
W (1): Warning: Rowsize (2624 bytes) could exceed row size limit, which is 1962 bytes.
<---所以,如果遇到此警告,为避免今后数据库操作存在潜在问题,可以larger max page size或者优化sql 语句或表的结构,避免row size 大于 max row size。
更多的资料可以参考官方文档:http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc20020_1251/html/databases/databases255.htm
此外,Sql Server数据库的max page size 要大些:8060byte。
- Max row size for Sybase
- Max row size for Sybase
- Data size bigger than max size for this type: 5829
- ERROR 1118 : Row size too large. The maximum row size for the used table type
- MySQL数据类型之CHAR与VARCHAR及row size max=65535bytes
- [MySQL 错误]ERROR 1118 (42000): Row size too large. The maximum row size for the used table type, not
- ERROR 1118 (42000): Row size too large. The maximum row size for the used table type, not counting B
- [MySQL 错误]ERROR 1118 (42000): Row size too large. The maximum row size for the used table type, not
- ERROR 1118 (42000): Row size too large. The maximum row size for the used table type, not counting B
- ERROR 1118 (42000): Row size too large. The maximum row size for the used table type, not counting B
- Row size too large
- mysql 报错:Row size too large. The maximum row size for the used table type, not counting BLOBs, is 65
- max fd size
- gdb max-value-size
- Row size too large (> 8126)
- MySQL出现The maximum row size for the used table type, not counting BLOBs, is 8126.错误
- Max pool size was reached
- UIView Why limit max size
- Android开发教程:蓝牙测试
- GCC后端及汇编发布(42)
- android开发环境配置
- GCC's bacl-end & assemble emission (42)
- GCC后端及汇编发布(43)
- Max row size for Sybase
- GCC's bacl-end & assemble emission (43)
- GCC后端及汇编发布(44)
- GCC's bacl-end & assemble emission (44)
- GCC后端及汇编发布(45)
- Linux内核网站已经恢复了
- Virtual Audio Cable使用笔记三:使用Virtual Audio Cable将播放的音频数据传输到录音机程序中
- GCC's bacl-end & assemble emission (45)
- MFC 重定义入口函数