c# - Query to break and get the value in dropdownlist -


i want query column break output , give result want.

for ex: if output of column

samarth nagar¸lokhandwla complex¸andheri(w)

i want display andheri(w) , if output single word andheri(w), should not break it

i m using sql-server 2005

here more details related tablename , columnname

select distinct add2 emp_mst 

try this:

select distinct    case      when charindex('¸', add2) != 0       reverse(substring(reverse(add2), 0, charindex('¸', reverse(add2))))     else add2   end emp_mst 

Comments