In table three columns with 1 milion records(here there is
no sequence values) i want add one more column with
sequence values from the first how it is posible?
Answer Posted / saraswathi muthuraman
SQL> desc ts_200;
Name Null? Type
----------------------------------------- --------
A NUMBER
SQL> alter table ts_200 add b number;
Table altered.
SQL> desc ts_200;
Name Null? Type
----------------------------------------- --------
A NUMBER
B NUMBER
SQL> select * from ts_200;
A B
---------- ----------
1
3
7
3 rows selected.
SQL> update ts_200 set b=rownum;
3 rows updated.
SQL> select * from ts_200;
A B
---------- ----------
1 1
3 2
7 3
3 rows selected.
| Is This Answer Correct ? | 7 Yes | 3 No |
Post New Answer View All Answers
What is interval partition?
Hi am new to PLSQL & facing problems in writing code like in SP, Functions, so any one having some SP coding with in depth explanation please share with me my Email ID suvarnaatsuvarna@rediffmail.com Or taking tanning on this please do contact me
What is string data type in sql?
How to combine two stored procedures in sql?
Which kind of parameters cannot have a default value in pl sql?
What is the advantage of nosql?
What is update query?
Which table is left in left join?
how to select unique records from a table? : Sql dba
Is sql workbench free?
what is a database? : Sql dba
Define join and name different types of joins?
What is left inner join in sql?
Is it possible to update views?
What are the types of functions in sql?