将数据从文本文件导入 MySQL 时 SSIS 包出错 [英] Error in SSIS package while importing data from text file into MySQL

查看:56
本文介绍了将数据从文本文件导入 MySQL 时 SSIS 包出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 SSIS 中创建了一个包.源是一个文本文件,目标是 MySQL.当我尝试运行包时,出现以下错误.

I created a package in SSIS. source is a text file and destination is MySQL. When I am trying to run the package, I am getting the following error.

"[ADO NET Destination [195]] 错误:数据插入时发生异常,提供程序返回的消息为:ERROR [42000] [MySQL][ODBC 5.2(w) Driver][mysqld-5.6.13-log]您的 SQL 语法有错误;请查看与您的 MySQL 服务器版本相对应的手册,以获取附近要使用的正确语法"

"[ADO NET Destination [195]] Error: An exception has occurred during data insertion, the message returned from the provider is: ERROR [42000] [MySQL][ODBC 5.2(w) Driver][mysqld-5.6.13-log]You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near"

推荐答案

您必须在 ODBC 数据库上执行此 SQL 脚本以忽略导致问题的双引号:

You have to execute this SQL script on the ODBC database to ignore double quotes which is causing the problem:

set @@global.sql_mode ='ANSI';

这篇关于将数据从文本文件导入 MySQL 时 SSIS 包出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆