1.what is the purpose of using alias name in sql server?
with certain example?

2.what is cursor?will u plz explain me in detail with
certain example?

Answers were Sorted based on User's Feedback



1.what is the purpose of using alias name in sql server? with certain example? 2.what is cursor?..

Answer / sujit sarkar

The main purpose of alias is we can define one object (like
table,column..) from another object which is used in sql
statement.
Suppose you need average salary and salary

then you can write

Select salary/12 as 'average salary' from salary

Is This Answer Correct ?    13 Yes 1 No

1.what is the purpose of using alias name in sql server? with certain example? 2.what is cursor?..

Answer / lekhrajdeshmukh

Cursor:- Cursor is special data type of mssql server.
Cursor is mainly used for extracting the row by row data
from tables.
cursor is the only data type that can not be used in table.
Cursor is mainly used in stored procedure and when we have
to use cursor in SP need to perform the following steps:-
1)declaring a cursor.
2)Open a Cursor
3) fetching the cursor
4)close the cursor.

Is This Answer Correct ?    9 Yes 0 No

1.what is the purpose of using alias name in sql server? with certain example? 2.what is cursor?..

Answer / lekhrajdeshmukh

Cursor:- Cursor is special data type of mssql server.
Cursor is mainly used for extracting the row by row data
from tables.
cursor is the only data type that can not be used in table.
Cursor is mainly used in stored procedure and when we have
to use cursor in SP need to perform the following steps:-
1)declaring a cursor.
2)Open a Cursor
4)close the cursor.

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More SQL Server Interview Questions

What function does a database engine serve in the sql server?

0 Answers  


Is mysql the same as sql server?

0 Answers  


what is difference between having and where clause ?

3 Answers  


What is the purpose of the model database?

0 Answers  


find the 3rd max salary

10 Answers  






What are the types of constraints?

1 Answers  


i have a table like this Eno ename 1 a 2 b 3 c i want to display ename and bossname from table hint boss is also an employee

3 Answers   NIIT,


can we have a nested transaction? : Sql server database administration

0 Answers  


What is a NOLOCK?

3 Answers   NA,


What are distinctive joins find as a part of sql?

0 Answers  


How to delete duplicate records based on single column from a table?

0 Answers   Petranics Solutions,


What is checkpoint in sql server?

0 Answers  


Categories