如何在Informatica中的一个文件中加载前一半记录,在另一个文件中加载前一半记录? [英] How to load the first half records in one file and other half in other file in informatica?

查看:48
本文介绍了如何在Informatica中的一个文件中加载前一半记录,在另一个文件中加载前一半记录?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

到目前为止,我已经尝试过将表达式转换与聚合转换一起使用以获得序列号的最大值.源是平面文件

I have tried expression transformation so far along with aggregate transformation to get the maximum value of the sequence number.Source is flat file

推荐答案

设计方式需要在映射中读取源两次,一次获取记录总数(如您所说的那样,最大顺序),然​​后另一个读取详细记录并将其传递给target1或target2.

The way you are designing would require reading the source twice in the mapping, one to get the total number of records (max sequence as you called it) and then another one to read the detail records and pass them to target1 or target2.

您可以通过传递记录数作为映射参数来简化它.

You can simplify it by passing the number of records as a mapping parameter.

无论哪种方式,决定何时路由到目标-您都可以通过将运行总计保留在变量端口中,每次通过该表达式的行通过并检查(记录数)来计数读取的记录数. /2.

Either way, to decide when to route to a target - you can count the number of records read by keeping a running total in a variable port, incrementing every time a row passes thru the expression and checking against the (record count)/2.

这篇关于如何在Informatica中的一个文件中加载前一半记录,在另一个文件中加载前一半记录?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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