4 votes 4 votes Can a sql query be like this: SELECT name AS instructor from instructor; The attributes' name can be renamed to table name or not? Databases sql databases + – vishwajit_vishnu asked Aug 13, 2017 vishwajit_vishnu 493 views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
Best answer 1 votes 1 votes I dont see any flaw with this.It should work. https://www.w3schools.com/SQL/trysql.asp?filename=trysql_select_all I ran :- SELECT CustomerName as Customers FROM Customers; Output:- Number of Records: 5 Customers Alfreds Futterkiste Ana Trujillo Emparedados y helados Antonio Moreno Taquería Around the Horn Berglunds snabbköp rahul sharma 5 answered Aug 14, 2017 selected Sep 3, 2017 by vishwajit_vishnu rahul sharma 5 comment Share Follow See all 0 reply Please log in or register to add a comment.
1 votes 1 votes It does not matter that ATTRIBUTE_NAME is same as TABLE_NAME or not. It works the same as before. Akash Verma 1 answered Sep 20, 2017 Akash Verma 1 comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes Yes, there is no problem in giving the name of attribute same as table name. eshita1997 answered Sep 26, 2020 eshita1997 comment Share Follow See all 0 reply Please log in or register to add a comment.