mysql - 如何将 tMysqlRow 中的选择查询结果记录到 Talend 中的 tLogRow?

标签 mysql talend

我有一个简单的工作,其中两个组件 tMysqlRow 通过 Row/Main 连接到 tLogRow。

我在 tMysqlRow 组件中有一个简单的 select 语句,我直接在数据库上测试了它,它可以工作并返回一条记录。当我运行该作业时,它显示“0.04 秒内有 1 行”,因此我认为这意味着 tMysqlRow 组件正在从数据库获取 1 行。

在 tLogRow 组件中,我按下了基本选项卡上的“同步列”按钮,当我编辑架构时,我可以看到所有列都在那里。

但是当我运行该作业时,它会记录以下内容:

Starting job LoadContextVariablesFromDBRecordDemo at 13:07 30/09/2015.
[statistics] connecting to socket on port 3714
[statistics] connected

||||||

[statistics] disconnected
Job LoadContextVariablesFromDBRecordDemo ended at 13:07 30/09/2015. [exit code=0]

所以我不知道为什么没有记录这些值?

我在这里做错了什么?

问候,

斯科特

最佳答案

所以我从 talend 论坛得到了一些建议,告诉我:

Do you really need to use tMysqlRow component? From what I understand, tMysqlInput is just the component you need. It directly returns the result of the query and propagates it into the flow. tMysqlRow component does not handle the returned data by default. In case you are restricted to use the tMysqlRow component, you have to check the Propagate QUERY's recordset in the Advanced settings of tMysqlRow component and then use the tParseRecordSet component to extract the data. For more information and guide, please, refer to the tMysqlRow Component Guide page. There is also an example on how to do this.

URL to the forum post

解决此问题后,我遇到了另一个问题,其中 tMysqlInput 组件显示警告消息:

the schema's dbType is not correct for this component

这也在同一线程中得到解决。

问候,

斯科特

关于mysql - 如何将 tMysqlRow 中的选择查询结果记录到 Talend 中的 tLogRow?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32857952/

相关文章:

esb - 如何暂停消息处理一段时间?

mysql - 解决在 Windows 上安装 MySql 8.0 和 Visual C++ Redistributable 的问题

mysql - 获取MYSQL中每个组的Top记录

Mysql数据库同步

java - Talend tExtractXMLField

mysql - 优化 MySQL 数据库的加载时间

php - php 中的嵌套循环的工作方式与预期不同

php - SQL Radius 在一个与另一个连接的表中搜索

java - 错误 : Could not find the main class