Reputation: 11
I need to add a column with varchar2
data type in teradata sql ,
for example
ALTER TABLE table_name ADD column_name varchar2 (20);
But in teradata its not taking varchar2
as a defined type name.
Upvotes: 1
Views: 961
Reputation: 23078
I think you should use NVARCHAR(20)
- pay attention to that extra N
in the type name, as it allows you to store Unicode strings.
Upvotes: 1
Reputation: 311393
varchar2
is an Oracle-specific datatype, not defined in the ANSI SQL standard. You should use the standard varchar
type instead:
ALTER TABLE table_name ADD column_name VARCHAR(20);
Upvotes: 5