Hi - I am trying to load to teradata using the fastload utility. As far as I can tell the command file is correct but I am getting an unusual error when I run it.
Here is the full output in the command prompt
This error is usually due to the Teradata Database telling FastLoad that the job is a restart, but there is no information in the FastLoad restart log table (SYSADMIN.FASTLOG) for that table.
Teradata keeps track if a table had already begun to be loaded by a FastLoad process.
try moving the begin loading statement
If i want to know if a table is locked by the fastload job/any fastload job is active on a source table, can i query SYSADMIN.FASTLOG for the presence of that source table ? I can see a field 'status' - with values 'loading init' in SYSADMIN.FASTLOG . So, do i need to check for a specific status that would tell this fload is still active on a source table or just an entry in SYSADMIN.FASTLOG for a source table means that it is locked ?
I know i can do this by simply doing a count(*) from that table which would give me an error that the table is being loaded, but i want to know this without firing a query on that table ?
If you can direct me to any manual link that has more details on this, then that would be great.
I wish I could say with a definitive answer that you can query the restart log as the solution for determining which tables are locked by a FastLoad job.
However, I have seen cases where FastLoad jobs begin, fail for some reason, the user cleans up the tables, but not the restart log table.
Thus, I suppose in most cases, you can use the restart log table, but possibly not as the official list of all tables currently locked.
Thanks Sreve for the reply.
I will go ahead assuming an entry is there in the restart log tabale.
During the migration from Td 13 to Td 14, TD GSC uses a utility called checkpending(not sure of the actual name, but something like this) to see if any tables have mload/fload locks on them. Any idea which tables contain this info. Just out of curiosity.
They are not recorded in any DBC or SysAdmin table. CheckTable PendingOp inspects the table header to find these persistent utility locks.