Hi ,
Can anybody tell me what is the problem with the below mapping.There is a one to many mapping between these two tables ie for a FacilityId I can have more than one Ratings,but by this mapping Iam getting only one Rating (ratingtypecode,ratingvalue) in my output
Hi Shong
That was my request itself
.. But that was only for a single table..There is a join between two tables here (a one two many join) ..
Please see my tMap mapping
Thanks
Abrar
I think you could process your data in two steps :
1)
You extract and put in 3 diffrents files your data and ONE of the fields MTerm, CiRating and CiRating.
Take one fileInput (with N lines in the file), one tMap and three fileOutputs, one output for each field MTerm, CiRating and CiRating.
2)
Then, you read the first file as Main row, and the others as lookups. So, you will be able to merge your commons data and your specific fields.
Take the three files in input of the tMap and connect one output which will contain N/3 lines at end of process.
Don't forget to use a ThenRun connection to separate these two processings.
Maybe someone will have an other idea ?
I agree with amaumont - you will need to pre-process the input file into 3 temporary outputs first. After a ThenRun you'll need to process the 3 outputs and join them on the key column(s). All of this assumes that you only need the columns defined in your output table.
If the size of your data isn't too large, then I'd suggest using the "hidden" components tArray and tArrayIn (please search the forum for information on these). You can then do the whole job "in memory".
Also please remember to be polite in the forum. Expecting an answer within 90 minutes, cross posting and bumping is not considered "forum etiquette".
c0utta
Thanks cOutta/amaumont for your suggestion.
Apologies for getting desperate to get the answer (had to submit POC to my manager about Talend)
I tried to solve this according to the below way
1.I used tFilterRow to filter rows ( I used only two rating types) into two different files.
2.Then used a tMap to map one of these files with the main query result
3.Thought of mapping the second file with the output of the tMap ,but as column names are same ,was not able to map the second file with the tMap o/p.Pls see the attached screen shot
4.Is there a way to map it this ways ??
BTW I think I can use tArray as my data size is very big
Thanks
Abrar