超出了Tcl值(2147483647字节)的最大大小
我试图通过Ubuntu控制台执行一个TCL脚本 控制台中的测试脚本执行示例超出了Tcl值(2147483647字节)的最大大小,tcl,ubuntu-14.04,Tcl,Ubuntu 14.04,我试图通过Ubuntu控制台执行一个TCL脚本 控制台中的测试脚本执行示例 tcl Main.tcl -file xxxx -test xxxx | tee test.log 它在没有执行脚本的情况下抛出了一条错误消息超过Tcl值(2147483647字节)的最大大小 我的机器TCL版本 % puts $tcl_version 8.6 % puts $tcl_version 8.4 我的机器TCL平台 % parray tcl_platform tcl_platform(byteOrd
tcl Main.tcl -file xxxx -test xxxx | tee test.log
它在没有执行脚本的情况下抛出了一条错误消息超过Tcl值(2147483647字节)的最大大小
我的机器TCL版本
% puts $tcl_version
8.6
% puts $tcl_version
8.4
我的机器TCL平台
% parray tcl_platform
tcl_platform(byteOrder) = littleEndian
tcl_platform(machine) = x86_64
tcl_platform(os) = Linux
tcl_platform(osVersion) = 3.13.0-32-generic
tcl_platform(pathSeparator) = :
tcl_platform(platform) = unix
tcl_platform(pointerSize) = 8
tcl_platform(threaded) = 1
tcl_platform(user) = vkosuri
tcl_platform(wordSize) = 8
% parray tcl_platform
tcl_platform(byteOrder) = littleEndian
tcl_platform(machine) = x86_64
tcl_platform(os) = Linux
tcl_platform(osVersion) = 2.6.28-19-generic
tcl_platform(platform) = unix
tcl_platform(threaded) = 1
tcl_platform(user) = vkosuri
tcl_platform(wordSize) = 8
但它在其他Ubuntu机器上运行良好,没有给出任何错误消息
其他机器TCL版本
% puts $tcl_version
8.6
% puts $tcl_version
8.4
其他机器TCL平台
% parray tcl_platform
tcl_platform(byteOrder) = littleEndian
tcl_platform(machine) = x86_64
tcl_platform(os) = Linux
tcl_platform(osVersion) = 3.13.0-32-generic
tcl_platform(pathSeparator) = :
tcl_platform(platform) = unix
tcl_platform(pointerSize) = 8
tcl_platform(threaded) = 1
tcl_platform(user) = vkosuri
tcl_platform(wordSize) = 8
% parray tcl_platform
tcl_platform(byteOrder) = littleEndian
tcl_platform(machine) = x86_64
tcl_platform(os) = Linux
tcl_platform(osVersion) = 2.6.28-19-generic
tcl_platform(platform) = unix
tcl_platform(threaded) = 1
tcl_platform(user) = vkosuri
tcl_platform(wordSize) = 8
有人能解释一下我的机器出了什么问题吗
谢谢
Malli看起来很像您可能在一块中分配的内存块大小上达到了限制。64位平台上的2GB限制是一个(分配给我的!),如果不彻底破坏ABI,就无法修复它,这就是为什么它还没有被修复的原因。当您达到极限时,Tcl将失败。它并不总是灾难性地失败——这部分取决于当问题发生时,它在C级的恢复环境是什么样的——但它肯定会死灰复燃
由于这是一个已知的问题,您最好的选择是找到一个解决方法。你能一次处理一点数据而不是一块处理一大块数据吗?(当然,我们需要看更多的代码来提出具体的建议。)问题是Ubuntu上的freeTDS包 第一种方法 这些查询在freeTDS==0.63时运行良好,但我的Ubuntu有freeTDS 0.93,现在我将freeTDS 0.93降级为0.63,运行良好 freeTds 0.63来源 在我的Ubuntu设备上设置SQL Server连接 必需的库/程序 配置
% puts $tcl_version
8.6
% puts $tcl_version
8.4
编辑/etc/odbcinst.ini并包括以下部分:
Description=SQL Server 2005
Driver-Driver=/usr/lib/odbc/libtdsodbc.so
第二次进近
将libtdsodbc.so复制到/usr/lib/odbc/
我已经把libtdsodbc.so放在我的谷歌硬盘里,你可以下载
希望它能起作用
谢谢
Malli我从数据库中获取了大量数据,基本示例是设置dbHandle[connectDB];设置hugeData[getAllProductInfoFromDB];getAllProductInfoFromDB过程失败,因为它正在从数据库中检索大量字符串。你能解释一下如何分割数据吗?用限制和偏移量调整SQL。每次循环记录一个区块。@Malli如果某个特定记录是罪魁祸首,则可以截断字符串。子字符串(nnn的列)。