Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9190

Re: Counting delemeters in a string

$
0
0

Rich Heilman presented a nice approach for this here on SCN some time ago (can't find the thread just now... )

 

So this works like this:

select length ('xyz,abc,cde,wer,123,fr,g')     - length ( replace ('xyz,abc,cde,wer,123,fr,g', ',', ''))  from dummy

 

Which tells us that you miscounted and that the result actually is 6

 

- Lars


Viewing all articles
Browse latest Browse all 9190

Trending Articles



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