Lookup
概要描述
获得一个关联的值。例如:源里包含 employee ID,但你还需要 employee name。
用于计算的植。例如:只是汇率或者个人所得税之类的固定数值,不是计算得出来的数据。
Update slowly changing dimension tables。主要是根据条件查出原表,若查出了,就把自己
添加的标志位设为真,否则就设置为假。
Connected or unconnected
Connected 和 unconnected 的 transformations 的输入和输出是不同的,不同点如表 2 列出的。
表 2
Connected Lookup Unconnected Lookup
从 pipeline 获得输入。 从另一个 transformation 的:LKP 的
表达式获得输入。
使用静态或者动态 cache。 使用静态 cache。
Cache 中 包 括 所 有 的 mapping 中 使 用 到 的 lookup
columns ( 就 是 condition 中 的 和 被 标 记 为 输 出 的
columns)。
Cache 中包括所有 condition 中的、
被标记为输出的 columns 以及被标
记为 return port 的。
同行能够返回多个 columns 或者加载到动态 lookup
cache 中。
每行只能返回一个 return port (R)。
如果没有匹配的数据,Integration Service 会返回一个
默认值。如果是动态缓存(cache),会加入一个新的
行或者放着他不管。
如果没有 匹配的数据, Integration
Service 会返回一个 NULL。
如果有匹配的数据,Integration Service 回返回一个结
果 包 括 所 有 被 设 置 为 输 出 的 值 。 如 果 是 动 态 缓
存,Integration Service 会任意的修改一行或者放着它
不管。
如 果 有 匹 配 的 数 据 , Integration
Service 会返回一个被设置为 return
port 的值。
输出所有的被标记为 output 的符合条件的数据。 返回一个值到使用:LKP 调用它的表
达式。
用户可以设置默认值。 用户不可以设置默认值。
评论2