|
Archives of the TeradataForumMessage Posted: Fri, 10 May 2002 @ 15:04:09 GMT
<-- Anonymously Posted: Friday, May 10, 2002 09:38 --> To get row counts for all tables you have to make two requests to the database and then format the results. Request one is a select against DBC.tables to get all table names. The results of this select are a set of select statements that look like" Select 'DB1.Tab1', count(*) from DB1.Tab1;. Then run the select counts. You can do this in BTEQ by directing the results of pass 1 into a file and then issuing a run file against the created selects. Another option would be to generate a set of insert or update statements instead of the select counts that put the counts generated in step 2 into a table. You could then dump out the table.
| ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
Copyright 2016 - All Rights Reserved | ||||||||||||||||||||||||||||||||||||||||||||||||
Last Modified: 15 Jun 2023 | ||||||||||||||||||||||||||||||||||||||||||||||||