Create table emp
(id number(9), name varchar2(20),salary
number(9,2));
The table has 100 records after table created.Now i nee to
change id's Datatype is to be Varchar2(15). now
Alter table emp modify(id varchar2(15),name varchar2(20),
salary number(9,2));
Whether it will work or returns error? post answer with
explanation.
Answer Posted / sathish p
We cant change column datatype while the column having
values.. Bcos error will come when u run the Alter table
modify statement...
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
Can we use having without group by in sql?
How do you delete data from a table?
How do I view a view in sql?
What is type and rowtype in pl sql?
What are the different set operators available in sql?
What is sql injection vulnerability?
what is row? : Sql dba
what are the advantages and disadvantages of views in a database? : Sql dba
what are the properties and different types of sub-queries? : Sql dba
Explain the order of sql statement execution?
Is it possible to remove child records without removing master table records...the two having pk,fk relationship?
what is sql profiler? : Sql dba
What is transaction control language (tcl)?
Does user triggers have entry for trigger with compilation errors?
What has stored procedures in sql?