. With the help of above table EMP, perform the following
operation is sql.
a) Add the new column “DEPTNO”
b) Rename the table
c) Update table
d) Modify the table if column ‘SAL’ whose data type is
number (10) and you want to enter varchar2 (15) . For
example $USD 20 etc.
Answer Posted / guest
create table emp(EMPID number(9),SAL number(10));
Result:creates a table named EMP.
a)alter table EMP add DEPTNO number(9);
Result:a new coloumn DEPTNO is added to the existing table EMP.
b)alter table EMP rename to EMP-RENAMED;
Result:renames the table name EMP to EMP-RENAMED.
c)update EMP-RENAMED
set SAL=SAL+10000
where EMPID>=xxxx;
Result:updates the salaries of Table emp depending upon the condition.
d)alter table EMP-RENAMED modify SAL varchar2(15);
Result:alters the SAL coloumn datatype to varchar2.
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Can anyone send me NIC question papers alongwith answers on nidhi1485@yahoo.co.in? Urgently needed.. Thanks in advance
In mainframe SDSF, Can we copy the list of jobs currently executing in SDSF in to a seperate DATASET...?
What is the Difference between in memory database and physical database
design a counter with the following repeated binary sequence: 0, 1, 2, 3, 4, 5, 6, 7, 8 using JK Flip Flop.
EXPLAIN UNARY OPEARATORS
Q2. A memory location has physical address D5687h. Compute: a. The offset address if the segment number is D445h. b. The segment number if the offset address is B577h.
How to know we are in home page of a web application using QTP
what are the missinschema properties and should we pass primary key in select command
what is dot net framework
How do you pass variables forwrd to future CECI sessions
what is integration testing in real time applications?
the systematic access of small computers in a distributed data processing system is referred as?
what is the main usage of an abstract keyword?please follow the program class A { void display() { System.out.println("hai"); } void print() { } } class B extends A { void print() { System.out.println("Hello"); } } In this program i was gives the implementation of print() according to my requirements in subclass.And there is no definition in superclass then why we can use abstract keyword before a method that i want to gives definition in other classes,is any mistakes in the above usage of method?
9.Difference between even and odd signals?explain with the diagram?
What is %Type,%Rowtype?