Post a reply

Write your message and submit

Options

Click in the dark area of the image to send your post.

Go back

Topic review (newest first)

ainiesta
2012-02-09 03:56:50

Hi There

tRecordMatch or trecordmathing --> I cannot find that component. I am using Talend Integrated Suite Professional Edition 4.1.1.
Is there any other component i can use in comparing csv and table and finding if there is duplicates before inserting?
Thanks

kraval
2012-02-08 17:44:58

In that case, try using the component trecordmatch.

Unfortunately I am not able to upload a screenshot on this post. But here's the layout

TableVALID --->  tmap  ----
                                       || (lookup)
                                       v
CSV ---> tmap (main)---> trecordmatch ---> matches ---> DBout (TableINVALID)
                                                           ---> no matches ---> DBout (TableINVALID)


you can configure the trecordmatch to find matches based on your criteria of uniquesness.

Option 2 will be to configure a lookup within tmap which involves inneroins and lookups and conditional outputs. This is an easier(lazy) way to configure


Best,
Karan

ainiesta
2012-02-08 08:17:54

Thanks.

But I need to compare first If the CSV file has records in the TABLE before inserting.

This is my scenario:

1. I want to insert CSV data to TABLE1 if there is no same existing records in that TABLE. (so this one i need to compare how i don't know?).
2. once compared and it sees that no duplicates will occur, CSV will populate that TABLE1. (how to pupulate this one based on number 1 scenario?)

Many thanks

kraval
2012-02-07 15:55:37

Hi there,

There's a component tuniqrow where in you can set the conditions for identifying a uniq row and you can set one of the outputs to table VALID and the rejects to table INVALID

csv >> tmap >> tuniqrow >> VALID
                              ||
                          INVALID


or you can replace tuniqrow by tmatchgroup and it will form groups of duplicates..

It all depends on whats your data that decides master record and duplicate record..

ainiesta
2012-02-07 11:36:02

Hi all, I have another question pls.

PROBLEM:
I have 2 tables (VALID, INVALID) and 1 CSV file.
I want to insert the CSV file into VALID table if it sees that there is no duplicate data in it. Otherwise, If upon entering of data and it sees that a duplicate item then it will enter to INVALID table.

by the way, I also created 1 column (statusCode) for both tables.
statusCode = 0 (duplicate)
statusCode = 1 (valid)


What and how is the best way to accomplish this.

Best regards.
Andres

Board footer

Powered by FluxBB