<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to count upcase letter from a string in Base SAS? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/How-to-count-upcase-letter-from-a-string-in-Base-SAS/m-p/703460#M215547</link>
    <description>&lt;P&gt;From the below string how can I count the no of upcase letter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data abc;&lt;BR /&gt;input name$30.;&lt;BR /&gt;datalines;&lt;BR /&gt;Name is Good&lt;BR /&gt;Name SHould Change&lt;BR /&gt;Name NOT Changed&lt;BR /&gt;;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 03 Dec 2020 18:25:10 GMT</pubDate>
    <dc:creator>vishalrajpoot3</dc:creator>
    <dc:date>2020-12-03T18:25:10Z</dc:date>
    <item>
      <title>How to count upcase letter from a string in Base SAS?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-count-upcase-letter-from-a-string-in-Base-SAS/m-p/703460#M215547</link>
      <description>&lt;P&gt;From the below string how can I count the no of upcase letter?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;data abc;&lt;BR /&gt;input name$30.;&lt;BR /&gt;datalines;&lt;BR /&gt;Name is Good&lt;BR /&gt;Name SHould Change&lt;BR /&gt;Name NOT Changed&lt;BR /&gt;;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Dec 2020 18:25:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-count-upcase-letter-from-a-string-in-Base-SAS/m-p/703460#M215547</guid>
      <dc:creator>vishalrajpoot3</dc:creator>
      <dc:date>2020-12-03T18:25:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to count upcase letter from a string in Base SAS?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/How-to-count-upcase-letter-from-a-string-in-Base-SAS/m-p/703462#M215549</link>
      <description>&lt;P&gt;1. Remove all lower case letters via REGEX or COMPRESS and count the length of the string&lt;BR /&gt;2. Convert it to all upper/lower case and see how many characters differ&lt;/P&gt;
&lt;P&gt;3. Use &lt;A href="https://documentation.sas.com/?cdcId=pgmsascdc&amp;amp;cdcVersion=9.4_3.5&amp;amp;docsetId=lefunctionsref&amp;amp;docsetTarget=n1qcntq4r6p3w3n1mtsnm58tbomc.htm&amp;amp;locale=en" target="_self"&gt;COUNTC()&lt;/A&gt; with capitalized letters and the modifiers to avoid listing all letters - your best option&lt;BR /&gt;&lt;BR /&gt;Typically when faced with a problem like this, I'll look through the &lt;A href="https://documentation.sas.com/?cdcId=pgmsascdc&amp;amp;cdcVersion=9.4_3.5&amp;amp;docsetId=lefunctionsref&amp;amp;docsetTarget=n01f5qrjoh9h4hn1olbdpb5pr2td.htm&amp;amp;locale=en" target="_self"&gt;SAS Functions by Category list&lt;/A&gt; and take a quick scan through all the character functions to see which ones could help me out.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Edited: to add countc() option.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/214824"&gt;@vishalrajpoot3&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;From the below string how can I count the no of upcase letter?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;data abc;&lt;BR /&gt;input name$30.;&lt;BR /&gt;datalines;&lt;BR /&gt;Name is Good&lt;BR /&gt;Name SHould Change&lt;BR /&gt;Name NOT Changed&lt;BR /&gt;;run;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 03 Dec 2020 18:33:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/How-to-count-upcase-letter-from-a-string-in-Base-SAS/m-p/703462#M215549</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2020-12-03T18:33:22Z</dc:date>
    </item>
  </channel>
</rss>

