Teradata - bulk insert from excel/txt file
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
20-01-21 08:39 AM
I have a process where i need to upload rows to a teradata table. I'm currently using a loop and an insert statement , however in some cases the collection that i need to insert is >1500 lines and therefore takes quite a while to complete. Is there a way i can insert the data from a file instead of having the loop?
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
20-01-21 06:29 PM
Hi @Kelly,
From my limited research it seems there are a few options for speeding up inserts with Teradata. The first I've seen discussed is making use of two different tables, assuming your target table already has data in it. In this case you would load your new records to a completely empty table and then perform a merge of that table into the actual target table. This can, reportedly, cut down on the overall time to insert.
Another option is to make use of some of the command-line tools Teradata supports like BTEQ or TPT. As I understand it, either of these tools could be used to handle bulk imports to Teradata from say a CSV or TXT file.
Cheers,
From my limited research it seems there are a few options for speeding up inserts with Teradata. The first I've seen discussed is making use of two different tables, assuming your target table already has data in it. In this case you would load your new records to a completely empty table and then perform a merge of that table into the actual target table. This can, reportedly, cut down on the overall time to insert.
Another option is to make use of some of the command-line tools Teradata supports like BTEQ or TPT. As I understand it, either of these tools could be used to handle bulk imports to Teradata from say a CSV or TXT file.
Cheers,
