Suppose we have a (assume relational) source table
Product_Id Month Sales
1 Jan x
1 Feb x
. . .
. . .
1 Dec x
2 Jan x
2 Feb x
. . .
. . .
2 Dec x
3 Jan x
3 Feb x
. . .
. . .
3 Dec x
. . .
. . .
and so on. Assume that there could be any number
of product keys and for each product key the sales
figures (denoted by 'x' are stored for each of the
12 months from Jan to Dec). So we want the result
in the target table in the following form.
Product_id Jan Feb March.. Dec
1 x x x x
2 x x x x
3 x x x x
.
.
So how will you design the ETL mapping for this case ,
explain in temrs of transformations.
Answers were Sorted based on User's Feedback
Answer / girish
Use an aggregator tx. Pass the ports (Product_id, Month,
Sales) to aggregator, group by Product_ID, manually create
12 ports for month like Jan, Feb, Mar, etc. Include an
expression for 12 ports, individually, as Jan -> IIF(Month
= Jan,Sales), Feb -> IIF(Month = Feb, Sales), etc.
Move these ports to the next transformation or to the
target. This should give the required output.
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / mukesh
Use an aggregator. Pass the ports (Product_id, Month,
Sales) to aggregator, group by Product_ID, manually create
12 ports for month like Jan, Feb, Mar, etc. Include an
expression for 12 ports,
Jan -> MAX(IIF(Month
= Jan,Sales)), Feb -> MAX(IIF(Month = Feb, Sales)), etc.
Without max, it will take last row..
Move these ports to the next transformation or to the
target. This should give the required output.
| Is This Answer Correct ? | 1 Yes | 1 No |
Answer / seekax
The reverse operation can be done using normalizer . . . To
carry out this process above mentioned we need to use
spliter in combination with joiner . . .
---- split using month -------- (into 12 sets of 2-columns)
1st SET 2nd SET
------- --------- . . . . .
product id,jan product id,jan
1,x 1,x
2,x 2,x
3,x 3,x
4,x 4,x . . . . . . .
---- join using product_id --------
Product_id Jan Feb March.. Dec
1 x x x x
2 x x x x
3 x x x x
| Is This Answer Correct ? | 0 Yes | 3 No |
Answer / janet
Simple SQL logic in the source qualifier sql will take care
of this issue.
Select product_id, month, sum(sales)
from source_table
group by product_id, month;
Then you can just pass the values straight through. No
need to split, aggregate, and join, etc.
| Is This Answer Correct ? | 4 Yes | 8 No |
I have 1200 records how can u send it in aggregator with good performance issues?
What is decode in static cache?
Explain what are the different types of transformation available in informatica.
whats the option in informatica 7 version is outdated in informatica 8 version onwards.
In my sourse i have like ename,gender vasu,male geetha,female ram,male suma.female kesav,male in my output i need male,female vasu,geetha ram,suma kesav
How to eliminate 1st and last rows from the source and load the inbetween rows.
What will happen if we have a filter transformation used in a mapping and in the filter condition we specify 1. Yes nothing else, only the number 1. In other words, assuming we have 10 rows coming to this filter transformation as an input, how many rows will be output by this transformation when we have only 1 in the filter condition?
what is mapping parameter and mapping variables
how many new transformations are introduced in 8.1 which are not available in 7.1? any new transformation in 8.6?
What is flashback table ? Advance thanks
how can we find the bottle neck in SQL Query in SOURCE QUALIFIER, and how can we tune it..?
What is an incremental loading? in which situations we will use incremental loading