Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/ssis/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
XML任务错误消息十六进制无效字符_Xml_Ssis_Task - Fatal编程技术网

XML任务错误消息十六进制无效字符

XML任务错误消息十六进制无效字符,xml,ssis,task,Xml,Ssis,Task,我正在开发一个SSIS包,用于将XML文件中的数据添加到现有SQL Server表中。我已经完成了几个类似的项目,但是在这个XML文件中,我从XML任务和数据流任务之间的数据流选项卡中得到了错误: Error: 0xC002F304 at XML Task, XML Task: An error occurred with the following error message: "'', hexadecimal value 0x15, is an invalid character. Lin

我正在开发一个SSIS包,用于将XML文件中的数据添加到现有SQL Server表中。我已经完成了几个类似的项目,但是在这个XML文件中,我从XML任务和数据流任务之间的数据流选项卡中得到了错误:

Error: 0xC002F304 at XML Task, XML Task: An error occurred with the following error message: 
"'', hexadecimal value 0x15, is an invalid character. Line 28, position 54.".
Error: 0xC002928F at XML Task, XML Task: Property "New Source" has no source Xml text; 
Xml Text is either invalid, null or empty string.
Task failed: XML Task
Warning: 0x80019002 at zSTU_TS_Element: SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED. The Execution method succeeded, but the number of errors raised (2) reached the maximum allowed (1); resulting in failure. This occurs when the number of errors reaches the number specified in MaximumErrorCount. Change the MaximumErrorCount or fix the errors.
SSIS package "zStu_TS_Element.dtsx" finished: Failure.
你知道我怎样才能解决这个问题吗

这是它从我的XML文件中引用的行:

<z:row c0='12' c1='80' c2='2006-04-17' c3='539' c4='1M2083N4N5N6N75800901110 11 '/>

这没有错。字符“U+0015否定应答”(0x15,ASCII 21)是一种控制代码,不能放入XML 1.0文件中。您拥有的XML文件格式不正确(因此不是真正的XML文件);尝试在任何其他XML读取器(例如IE)中打开它,您将得到相同的错误

您需要使用文本编辑器将该字符从文件中删除,并查看生成该字符的任何中断源


(不幸的是,我们看不到张贴在这里的字符,因为它是一个典型的不可见控制代码,StackOverflow会过滤掉。但是,一个好的文本编辑器应该能够显示它所在的某种标记。错误中的列号表明它位于
c4
属性值的开头,尽管这不是n必须可靠。)

谢谢!我只是研究了一下自己,你说的没错。我研究了一下XML 2.0,但它似乎也不支持这个字符。你能确认一下吗?XML 1.1允许字符,但只编码为字符引用,例如
;
。这样做没有什么意义。XML 2.0目前不存在,只是关于删除XML遗留问题的想法正在讨论中。