Arithmetic overflow error converting IDENTITY to data type int(将 IDENTITY 转换为数据类型 int 的算术溢出错误)
问题描述
通过 vb 代码运行时,将 IDENTITY 转换为数据类型 int 时发生算术溢出错误.但是当我执行存储过程时,数据被正确插入.
Arithmetic overflow error converting IDENTITY to data type int, is occurring when running through vb code. But when I execute the stored procedure, data gets inserted properly.
通过应用程序有时也可以,有时不可以.
Through application also sometimes this works and sometimes it doesn't.
当我检查当前标识值和当前列值不同时.这是否属于问题.
When I check the current identity value and current column values are different. IS this falls under issue.
请告诉我如何解决它.
推荐答案
2147483647 是 INT 的最大尺寸,所以你的 IDENTITY 是比这个大.您可以使用 BIGINT 来解决您的错误,假设您的 IDENTITY 不会超过 9223372036854775807.
2147483647 Is the maximum size for INT so somewhere your IDENTITY is larger than this. You can use BIGINT instead to get around your error, assuming your IDENTITY won't surpass 9223372036854775807.
这篇关于将 IDENTITY 转换为数据类型 int 的算术溢出错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:将 IDENTITY 转换为数据类型 int 的算术溢出错误
- 如何将 SonarQube 6.7 从 MySQL 迁移到 postgresql 2022-01-01
- 使用 Oracle PL/SQL developer 生成测试数据 2021-01-01
- 如何将 Byte[] 插入 SQL Server VARBINARY 列 2021-01-01
- 远程 mySQL 连接抛出“无法使用旧的不安全身份验证连接到 MySQL 4.1+"来自 XAMPP 的错误 2022-01-01
- SQL 临时表问题 2022-01-01
- 导入具有可变标题的 Excel 文件 2021-01-01
- 如何使用 pip 安装 Python MySQLdb 模块? 2021-01-01
- 以一个值为轴心,但将一行上的数据按另一行分组? 2022-01-01
- 更改自动增量起始编号? 2021-01-01
- 在SQL中,如何为每个组选择前2行 2021-01-01
