Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

find matching data in columns

$
0
0

Id     Seg       Value          St    Unit 

124009 HIGHMANMD percent
124015 HIGHMANMD percent
124021 HIGHMANMD percent
124021 HIGHMANMD Acres
124023 HIGHMANMD percent
124043 HIGHMANMD percent
142001 HIGHMANPA      Acres
142023 HIGHMANPA percent
142023 HIGHMANPA percent
142035 HIGHMANPA percent
142037 HIGHMANPA percent
142063 HIGHMANPA percent
142075 HIGHMANPA percent
142097 HIGHMANPA percent
142107 HIGHMANPA percent
142113 HIGHMANPA percent
142119 HIGHMANPA percent
142127 HIGHMANPA percent

I have the above result from joining set of tables , all i want to find now is

if there are values dulpicated and

also if  i have  seg , value, st    matches unit ( acres and percent ) i should throw an error 

1. If I have 

42023HIGHMANPApercent
42023HIGHMANPApercent

I should throw error 

2.if i have 

      24021HIGHMANMDpercent
      24021HIGHMANMDAcres

Can any one please help me 

Thanks


Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>