Skip to content

Alter table column size oracle

In this post, we will learn how to modify the size of an column in oracle table. It’s easy to alter the column size using the ALTER TABLE MODIFY statement.

Sometimes the column value will exceed from which we defined while creating the table. So in that case we need to update the size of the column again.

Syntax

ALTER TABLE table_name 
MODIFY column_name column_type;

Lets take the table as EMPLOYEES for understanding. To know the existing size of an each column you can describe the table like below,

DESC EMPLOYEES;

The result will be like this,

Now we going to alter the size of the EMP_NAME column, you can write a query like in the below code snippet.

ALTER TABLE EMPLOYEES
MODIFY EMP_NAME VARCHAR2(50);

DESC EMPLOYEES;

Result

Happy Querying 🙂

SQL
, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.