Home Page for the TeradataForum
 

Archives of the TeradataForum

Message Posted: Mon, 13 Feb 2006 @ 22:03:26 GMT


     
  <Prev Next>   <<First <Prev Next> Last>>  


Subj:   Re: Removal of FORMAT clauses
 
From:   McCall, Glenn David

I had a look at the manual and tend to agree there is not syntax to drop attributes from a column. Hopefully I will be proven wrong.

Thinking outside the box (pun intended), you say that these scripts have been created from another database. Have you considered modifying the DDL before running it against Teradata?

If you have Ultraedit (a pretty cool tool) or any other tool that supports regular expressions try replacing this:

     format\s+'.*'

with an empty string.

The regular expression says search for the word format followed by one or more whitespace characters (\s) then a single quote followed by any number of any characters (.*) and a trailing single quote.

As with anything like this, always keep a copy of the original.


Regards

Glenn Mc


P.S. if you find that the regular expression pretty much wipes out all of the file from the first format to the final single quote, your regular expression is probably working in "greedy" mode (match as much as possible).

If you find this, let me know and I will give you a "lazy" expression.



     
  <Prev Next>   <<First <Prev Next> Last>>  
 
 
 
 
 
 
 
 
  
  Top Home Privacy Feedback  
 
 
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 15 Jun 2023