Let us suppose we have a table with structure in order
empno
empname
empdesig
empcountry
and now i want to re-organize the columns of this table to
empno
empdesig
empname
empcountry
how can i do this with queries ?
assume that table contains the data.
Answer Posted / jyothi
there is only one way to to re-arrange the table
that is views...
create view <view-name>as select <fields> from <tablename>
.........
for example..
create view vw as select empno,empdesig,empname,empcountry
from <tablename>...
(u can get message that is view created)
just display the data using viewname(vw)..
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is difference between inner join and cross join?
What is rollback?
What are all the different normalization?
What is raid? How does it help storage of databases?
What is %type in sql?
Can a view be mutating? If yes, then how?
What are string functions in sql?
What do you mean by table in sql?
What is a trigger in sql?
Which data dictionary views have the information on the triggers that are available in the database?
Explain the rollback statement?
what is 'mysqld'? : Sql dba
How do sql triggers work?
What port does sql server use?
Can we commit inside a trigger?