Archives of the TeradataForum
Message Posted: Thu, 19 May 2016 @ 11:11:11 GMT
| Subj: | | Re: Alter Table - Add Columns |
| |
| From: | | Dieter Noeth |
Sridhar K wrote:
| | Could you please advise why Teradata Alter table statements for adding new columns takes lot of time for Large tables. | |
| | I think this is normal if we are giving some default values where it as to rewrite the entire table. | |
Teradata is not Oracle where NULL columns at the end of the record are not stored.
E.g. you add a new DATE column, then every record is modified to add a four byte NULL DATE. But when you add "newcol DATE COMPRESS NULL" it
might not be necessary to change every record if a NULL-bit is available (otherwise every record must be changed to add new NULL-byte).
Dieter
|