问题

在使用sqoop导入数据时,报如下错误:

ERROR manager.SqlManager: Error reading from database: java.sql.SQLException: Streaming result set com.mysql.jdbc.RowDataDynamic@2cbefcfd is still active. No statements may be issued when any streaming result sets are open and in use on a given connection. Ensure that you have called .close() on any active streaming result sets before attempting more queries.
java.sql.SQLException: Streaming result set com.mysql.jdbc.RowDataDynamic@2cbefcfd is still active. No statements may be issued when any streaming result sets are open and in use on a given connection. Ensure that you have called .close() on any active streaming result sets before attempting more queries.

原因

原因是mysql-connector-java-。。。-bin.jar这个jar包出现了问题,可能是版本太低的原因。

解决方案

http://download.csdn.net/detail/heixiazuoluo10254222/7706781
在这里下载mysql-connector-java-5.1.31-bin
并替换掉原来sqoop目录下lib文件夹下的连接数据库jar包。这样就不会有问题了,如下截图。
这里写图片描述

Logo

GitCode 天启AI是一款由 GitCode 团队打造的智能助手,基于先进的LLM(大语言模型)与多智能体 Agent 技术构建,致力于为用户提供高效、智能、多模态的创作与开发支持。它不仅支持自然语言对话,还具备处理文件、生成 PPT、撰写分析报告、开发 Web 应用等多项能力,真正做到“一句话,让 Al帮你完成复杂任务”。

更多推荐