All Forums Database
KVB 124 posts Joined 09/12
22 Mar 2015
Execute a set of DDL's as a single script

Hi All,
 I have a set of DDL's where I need to execute them only all the syntaxes are correct else I dont need to execute any of the statement in the script.
I tried with MSR and came to know that it supports only DML.
What's the best approach that suits this requirement.
Any help in this regard is appreciable.
 
Regards
KVB

dnoeth 4628 posts Joined 11/04
23 Mar 2015

You're running CREATEs without prior testing?
Why don't you check the DDLs in a development database?

Dieter

KVB 124 posts Joined 09/12
23 Mar 2015

Yes.Those statements will be checked in DEV and QA.But as part of the automation process,we prior check and execute.
We have all the create statements in one file and DML's in another.While placing them in files,there are chances of copy/paste mistakes.
That's the reason we are trying to do this.
Any help in this regard is appreciable.

teradatauser2 236 posts Joined 04/12
23 Mar 2015

Did you weigh the option of using BT ET in Teradata mode in bteq? If any one of them fail, both will roll back. You need to check if DDLs are allowed in this.

.LOGON

BT; (txn #1)

INSERT row1;

INSERT row2;

ET;

.LOGOFF

You must sign in to leave a comment.