Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 How to give the color in sql query result

Author  Topic 

itnagaraj
Yak Posting Veteran

70 Posts

Posted - 2011-09-06 : 09:28:13
Select userId,userFirstName,isactive from tblUserDetails Where userId Like 'a%'

The above query returns the following result.
userId userFirstName isactive
amar amar 1
anand anand 0
arun_ar Arun 0

but i want to display the data in red color if isactive=0 like
userId userFirstName isactive
amar amar 1
anand anand 0
arun_ar Arun 0


V.NAGARAJAN

karthik_padbanaban
Constraint Violating Yak Guru

263 Posts

Posted - 2011-09-06 : 09:43:57
Giving color needs to be done in front end. and if there is no other way then convert your result to XML and add color tags.

Karthik
http://karthik4identity.blogspot.com/
Go to Top of Page
   

- Advertisement -