i have a table #temp1(id, Name groupname ) and record
like this 1 R1 S
2 R3 S
3 R2 S
4 R4 D
5 R5 D
6 R6 K
7 R7 K
8 R8 L
9 R9 L
10 R10 L
11 R11 K
and i want to display record based on user defind sorting
order e.g.
1 R4 D
2 R5 D
3 R6 K
4 R7 K
5 R11 K
6 R1 S
7 R3 S
8 R2 S
9 R8 L
10 R9 L
11 R10 L
Answer Posted / archana
Select * from #emp Order by id,Groupname
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Explain various On-Delete options in a DB table. Which is the default option?
Why do we use sql limitations? Which constraints can we use while making a database in sql?
What is inner join? Explain with an example?
Does a specific recovery model need to be used for a replicated database? : sql server replication
When would you use a before or after trigger?
What are parameterized reports?
In what three ways is the return statement used in a stored procedure?
Can an automatic recovery be initiated by a user?
What have included columns when we talk about sql server indexing?
Explain indexed views?
What are the advantages of using third-party tools?
What is log shipping? Can we do logshipping with SQL Server 7.0 - Logshipping is a new feature of SQL Server 2000. We should have two SQL Server - Enterprise Editions. From Enterprise Manager we can configure the logshipping. In logshipping the transactional log file from one server is automatically updated into the backup database on the other server. If one server fails, the other server will have the same db and we can use this as the DR (disaster recovery) plan.
How do you open a cluster administrator?
Describe in brief system database.
what is the difference between writing data to mirrored drives versus raid5 drives. : Sql server administration