【问题标题】:talend - output of tMap to another querytalend - tMap 到另一个查询的输出
【发布时间】:2023-06-22 07:34:01
【问题描述】:

我有一个单视图查询(非常繁重),所以我想避免再次重新查询。

此查询的输出被转换并放入文件中。此文件有一个唯一的参考编号(查询中的字段参考)。

我需要在第二个查询中作为 where 子句输入的“引用”。

我正在考虑这个流程: 第一个子任务:

                                  tOutputFile     
                                   /   
tOracleInput ->  tMap -> tReplicate
                                   \
                                  tMap (will only map the reference field)
                                     \
                                     tSetGlobalVar 
                                        (set to a list, and add to globalMap)

完成该子作业后,将运行下一个子作业;

tOracleInput (build the where clause from the list from globalMap) -> tMap  -> tOutputFile

这个设计好看吗?还是我最好在我的第二个 tOracleInput 中对参考编号使用子查询?

SELECT ... FROM table1 WHERE references  IN (SELECT references from BIGVIEW WHERE ...)

【问题讨论】:

    标签: sql oracle talend talend-mdm


    【解决方案1】:

    根据为引用字段检索到的不同值的数量,查询应超过 Oracle 授权的最大长度。
    您应该考虑使用“在每一行重新加载”查找模型提供的工具将这些值与第二个 tOracleInput 连接起来。
    了解它是如何工作的 here

    希望这会有所帮助。

    【讨论】:

      最近更新 更多