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 / shailesh j
If column contains data then we can only modify size of
column without changing its data type. But if the column is
empty then we can modify its size as well data type.
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
First round ------------------- - Procedure - Packages - Views - Virtual tables - Can we use dcl with in function? - Joins and few scenarios - Triggers and its type - Pragma, type and its functionality - How to create db link in oracle - Materialized view - How to find duplicate values from table? - Cursor and its functionality - Write a script to display friday and its date from a entire year. - Exception Handling Second round ------------------------ Gave a scenario like. Need to write a function to perform. When user try to change a password. It must not be last five password and a given password can be combination of characters, symbols, upper and lower case.
What is delimiter in pl sql?
What is difference between my sql and sql?
what are the types of subquery? : Sql dba
Explain what is a database?
Why do we need cursor in pl sql?
What is using in sql?
How do you know if a relationship is 2nf?
How do you change a value in sql?
Write an sql query to select all records from the table?
What are aggregate functions in sql?
what is the difference between ereg_replace() and eregi_replace()? : Sql dba
How to avoid using cursors? What to use instead of cursor and in what cases to do so?
What is difference between stored procedures and application procedures?
what are the 'mysql' command line options? : Sql dba