Xml字符串抛出outofmemory异常 [英] Xml string throwing outofmemory exception
问题描述
您好,
我需要将数据表传递给存储过程。我正在使用Datatable.writexml使用StringBuilder将表转换为xml,然后使用StringBuilder.ToString()将stringbuilder转换为字符串,当数据表超过一定数量的数据行时,这会抛出内存异常
。
I need to pass a datatable to a stored procedure. I'm using Datatable.writexml to convert the table into an xml using a StringBuilder and then converting the stringbuilder into a string using StringBuilder.ToString(), which is throwing out of memory exception when datatable exceeds certain number of datarows.
请建议处理此内存异常的方法。
Please suggest ways to handle this memory exception.
如果字符串无法处理大型数据表的xml,还有其他方法将数据表传递给存储过程?
If string cannot handle a large datatable's xml, is there any other way to pass datatable into a stored procedure?
谢谢,
Raj
Raj Muthusamy
Raj Muthusamy
推荐答案
您好,
请提供有关该问题的更多详细信息。信息,如确切的错误消息和
Please provide more details about the issue. Information such as, exact error message and
发生错误的源代码。
  ;谢谢:)
Thanks :)
这篇关于Xml字符串抛出outofmemory异常的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!