|
|
|
Ten Centuries
      
Group: General Forum Members
Last Login: Thursday, April 19, 2012 10:25 PM
Points: 1,231,
Visits: 3,483
|
|
Adequate and nice to learn To get the exact result
select * from #Like_Test where Col1 Like '%Cu[_]%'
‘_’ is escape so [_] is the valuable one
|
|
|
|
|
SSC-Dedicated
           
Group: General Forum Members
Last Login: Today @ 10:27 AM
Points: 37,648,
Visits: 29,900
|
|
Or
select * from #Like_Test where Col1 Like '%Cu/_%' ESCAPE '/'
Gail Shaw Microsoft Certified Master: SQL Server 2008, MVP SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
We walk in the dark places no others will enter We stand on the bridge and no one may pass
|
|
|
|
|
Valued Member
      
Group: General Forum Members
Last Login: Sunday, February 26, 2012 1:57 AM
Points: 57,
Visits: 32
|
|
Try this to get the records start with "Cu_"
select * from #Like_Test where Col1 Like 'Cu[_]%'
|
|
|
|
|
Ten Centuries
      
Group: General Forum Members
Last Login: 2 days ago @ 7:40 PM
Points: 1,059,
Visits: 1,150
|
|
good basic question of LIKE.. I like it
|
|
|
|