Why do we need to create an alias if we can directly use
the table name? What are the benefits of referring a table
name by its alias?
Also, when should we go for alias and when for synonyms?
Answer Posted / siva
let us consider we have a database with no of tables and one table name is ComputerScienceAndEngineering_Departement
if any one want to access this table they should use full name
ex: select * from ComputerScienceAndEngineering_Departement ;
it may be difficult to someone and sometimes to us also .
so if we creating alias like csedept then it will become simple to access it.
An alias is simply an alternate name for a table or view. Like tables and views, an alias can be created, dropped, and have comments associated with it.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the use of value function?
What parameters are used to control the free space in DB2?
What is the role of data manager in the db2 database?
Explain how can you do the explain of a dynamic sql statement?
List some fields from sqlca?
Mention the location where the output received from explain statement is stored.
What is cursor with hold option in db2?
How do you stop a db2 database in linux?
What are the uses of db2 optimizer?
How do I connect my db2 database to ibm?
Can we update view in db2?
What is the syntax for FETCH in DB2 ?
Which component is used to execute the sql statements?
What is meant by explain?
What do you mean by cursor?