I don't know exactly the best way to realize the following.
I need to process a list of file to put the content (each line) in DB.
I use the following structure :
tFileList (list each file) -> Iterate -> tFileInputRegex (extract only some line) -> Main ->tMap (add info) -> Main -> tOracleOutput.
The process is good but I don't know the correct "Action on table" to make.
I would like to drop the table and create only one time by execution not by file (by iteration) but I don't know how to do this.
Thanks in advance
If you are looking to iterate the result set from a file at the rate of one record per execution, then the best way to do it is by using tFlowtoIterate. Please refer the link below to get details about this component.
Now, coming to your query about what you need to select for Action on table, the answer depends on your specific requirement. The details for various values are as shown below. If you are having any further queries, please feel free to reply to the post.
Default: No operation is carried out.
Drop and create table: The table is removed and created again.
Create table: The table does not exist and gets created.
Create table if not exists: The table is created if it does not exist.
Drop table if exists and create: The table is removed if it already exists and created again.
Clear table: The table content is deleted.
Truncate table: The table content is deleted. You do not have the possibility to rollback the operation.
Please appreciate our Talend community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved :-)
No... I would like to iterate on each file to extract n lines, keep n lines and after process n lines in one flow.
Today, I do the following :
a subjob, with :
tFileList (list each file) -> Iterate -> tFileInputRegex (extract only some line) -> Main ->tMap (add info) -> Main -> tDeilimitedFileOutput
And onsubjob ok : tDelimitedFileInput -> tOracleOutput
It's work but I have a temporary file maybe the best design.
Talend named a Leader.
Kickstart your first data integration and ETL projects.
Watch the recorded webinar!
Pick up some tips and tricks with Context Variables
Learn how media organizations have achieved success with Data Integration
Look at6 ways to start utilizing Machine Learning with Amazon We Services and Talend