I have one table and column is c1 pk, c2 not null,c3 not
null and 200 row in it and i add c4 column and value, how
can is possible

Answers were Sorted based on User's Feedback



I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / manoj

1.
alter table <table_name>
add column<col_name> <data_type>[not null];

2.
for inserting values

Depends: if u have data in another table than u can insert
by making small packege (using cursor)

OR :u can also sequence to insert

Is This Answer Correct ?    2 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / premraj

alter table table_name add c4 varchar2(30) default null

Is This Answer Correct ?    2 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / asraf

ALTER TABLE DUMMY1 ADD (C4 VARCHAR2(100) DEFAULT 0)

Is This Answer Correct ?    1 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / ravi singh

You can alter the table but u can not make the column as
null, and your insert statement will depends upon the
condition that u specified.

Is This Answer Correct ?    0 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / gayathri

Alter table tablename ADD(columnname (data_type) notnull)

Is This Answer Correct ?    0 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / ramprasad.s

hi


Alter Table <Table Name> ADD( <Column name> <data type>)

you can insert values by using <update> with reference

to the existing values of the other columns.
bye

sun_ramprasad@yahoo.com

Is This Answer Correct ?    0 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / jyothi

alter the table -> alter table <table name> <datatype>
after then u can insert values in that clounm bu using
UPDATE ...
update set column name= value where condition
condition ....where u want to update the value means which
row...

Is This Answer Correct ?    0 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / srinivas

alter table <table-name> add(<column-name> datatype
[constrains]);

Is This Answer Correct ?    0 Yes 0 No

I have one table and column is c1 pk, c2 not null,c3 not null and 200 row in it and i add c4 column..

Answer / shaik

u can alter the table. after that u can add the data
depending upon the criteria condition.

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More SQL PLSQL Interview Questions

Can we update views in sql?

0 Answers  


What is record variable?

0 Answers  


differentiate between float and double. : Sql dba

0 Answers  


What are the 3 types of behavioral triggers?

0 Answers  


Hello All, Could any well write a query for the following scenario. Account(table name) No Name Amount 1 ABCD 2000.00 2 DEFG -2000.00 3 GHIJ 3000.50 4 JKLM 4000.00 5 MNOP 6000.00 O/p Should be in this format No Name Credit Debit 1 ABCD 2000.00 0 2 DEFG 0 -2000.00 3 GHIJ 3000.50 4 JKLM 0 -4000.00 5 MNOP 6000.00 o could any one give appropriate query for this Thnks in Advance Suneel Reddy

6 Answers   Target,






Which are the most commonly used sql joins?

1 Answers  


What does select * from mean in sql?

0 Answers  


Explain sql data types?

0 Answers  


Explian rowid, rownum? What are the psoducolumns we have?

0 Answers  


How do I view an execution plan in sql?

0 Answers  


how to create object in plsql

2 Answers   TCS,


What are the different types of dbms?

0 Answers  


Categories