![]() |
|
Archives of the TeradataForumMessage Posted: Tue, 14 Aug 2007 @ 18:12:16 GMT
... for the input. I'm going to use the method that constructs the Bteq script from SQL, mentioned by Dave Curley. Since I particularly want to run it from Windows, I've created a Stored Procedure that simply takes in two parameters : DB_NM, TABL_NM. It validates that the table does indeed exist and then writes the values to a Control Table. This Control table is then Inner Joined to Dave's query, thereby restricting what's generated down to one table. Here's an example output that's generated in a file:
.os del DEVCE_T.COUNTRY.ddl
.export file=DEVCE_T.COUNTRY.ddl
show table DEVCE_T.COUNTRY;
.export reset
Might not be as elegant as the Unix solution, but I'm happy. Cheers, Dave Clough
| ||||||||||||||||||||||||||||||||||||||||||||||||
| | ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
|
| ||||||||||||||||||||||||||||||||||||||||||||||||
| Copyright 2016 - All Rights Reserved | ||||||||||||||||||||||||||||||||||||||||||||||||
| Last Modified: 15 Jun 2023 | ||||||||||||||||||||||||||||||||||||||||||||||||