Archives of the TeradataForum
Message Posted: Mon, 14 Sep 2015 @ 13:51:27 GMT
<-- Anonymously Posted: Monday, September 14, 2015 1:59 -->
Our system has a Staging table which is exactly of the same structure as the base table. The staging table has NO Primary Index defined. The plan (so far) is to use Fastload to load the Staging table using Datastage and then use bteq insert/select to "insert" the data from the staging table to the base table. No delete or updates are required. We are using DataStage to load the data from source to the Staging table.
My questions are -
- What sort of error can I expect while performing the insert/select into the base table? I am ruling out data-type issues since the staging table has the same structure as the base table and data is already correctly loaded to the staging table first. So available data in the staging table should move to the base table without any hassle. Are there any other issues i can possibly face ?
- From a design perspective, what are the pros & cons of removing the staging table layer and loading data directly to the base table using Multiload ? Some of the base tables are loaded incrementally and thus may have data already present. In such cases I cant use Fastload since the table wont be empty. So I am thinking that if Mload is used there will be a table-level lock and if there is a data issue while loading the table, the lock won't be released automatically and there could be data consistency issues. The dba's would have to release the lock manually. So i believe it will be better to have a Staging table to weed off errorneous records before proceeding to load the base/final table.
- Since we will be using Datastage to load data via Mload/Fastload will the Error and Log tables be created and dropped by the TD utilities automatically if the load succeeds?
I apologize if the above questions seem to be unintelligent.
|Copyright 2016 - All Rights Reserved|
|Last Modified: 28 Jun 2020|