<?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 Re: Remove text from a string using python or arcade in Developers Questions</title>
    <link>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590718#M4010</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Using Arcade you could so something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;var firstSpace = find(' ',$feature.ADDRESS,0)&lt;BR /&gt;var strCount = count($feature.ADDRESS)&lt;BR /&gt;var strDiff = strCount - firstSpace&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;return right($feature.ADDRESS, strDiff)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 22 Jul 2019 14:40:51 GMT</pubDate>
    <dc:creator>MarkBockenhauer</dc:creator>
    <dc:date>2019-07-22T14:40:51Z</dc:date>
    <item>
      <title>Remove text from a string using python or arcade</title>
      <link>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590716#M4008</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="background-color: #ffffff;"&gt;I need some help with a field calculator expression, using&amp;nbsp;python or arcade, in ArcGIS Pro&lt;/P&gt;&lt;P style="background-color: #ffffff;"&gt;I have an address field that has full address, with street number and name,&amp;nbsp;I want to remove the number and retain only the street name, since the number of digits in the address could vary so I want to remove everything that comes before the space, so first word or an element. I am trying to do this using field calculator in ArcGIS&amp;nbsp;Pro, so&amp;nbsp;either Python 3 or Arcade.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;For example :&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;SPAN style="color: inherit; border: 0px; font-weight: inherit; font-size: 10.5pt;"&gt;3405 S 51st St&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;SPAN style="color: inherit; border: 0px; font-weight: inherit; font-size: 10.5pt;"&gt;would result in&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;SPAN style="color: inherit; border: 0px; font-weight: inherit; font-size: 10.5pt;"&gt;S 51st St&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;I tried this&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;!ADDRESS!.split(" ")[1:] , it did not work.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;I looked at this &lt;A _jive_internal="true" href="https://community.esri.com/thread/233144-remove-text-in-parenthesis-with-arcade"&gt;https://community.esri.com/thread/233144-remove-text-in-parenthesis-with-arcade&lt;/A&gt;,&amp;nbsp;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&amp;nbsp;but couldn't figure out how to&amp;nbsp;do this with arcade.&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;SPAN style="color: inherit; border: 0px; font-weight: inherit; font-size: 10.5pt;"&gt;If I can get some help with correct&lt;/SPAN&gt;&lt;SPAN style="font-size: 11pt;"&gt;&amp;nbsp;syntax for python or an arcade expression would be great.&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; font-size: 11pt; margin: 0in 0in 0.0001pt;"&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jul 2019 13:59:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590716#M4008</guid>
      <dc:creator>SRJS4</dc:creator>
      <dc:date>2019-07-22T13:59:45Z</dc:date>
    </item>
    <item>
      <title>Re: Remove text from a string using python or arcade</title>
      <link>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590717#M4009</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="https://community.esri.com/migrated-users/192682"&gt;Saloni,&lt;/A&gt;‌&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using Python&amp;nbsp;&lt;SPAN style="display: inline !important; float: none; background-color: #ffffff; color: #3d3d3d; font-family: arial,helvetica,'helvetica neue',verdana,sans-serif; font-size: 14.66px; font-style: normal; font-variant: normal; font-weight: 400; letter-spacing: normal; orphans: 2; text-align: left; text-decoration: none; text-indent: 0px; text-transform: none; -webkit-text-stroke-width: 0px; white-space: normal; word-spacing: 0px; word-wrap: break-word;"&gt;&lt;STRONG&gt;!ADDRESS!.split(" ", 1)[1]&lt;/STRONG&gt; should work for you assuming there are no leading spaces before the address number and addresses do not contain any unit numbers such as "123 C Main Street".&amp;nbsp; You can add a strip() statement to remove leading and trailing spaces such as&amp;nbsp;&lt;STRONG&gt;!ADDRESS!.strip().split(" ", 1)[1].&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jul 2019 14:12:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590717#M4009</guid>
      <dc:creator>LanceCole</dc:creator>
      <dc:date>2019-07-22T14:12:21Z</dc:date>
    </item>
    <item>
      <title>Re: Remove text from a string using python or arcade</title>
      <link>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590718#M4010</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Using Arcade you could so something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;var firstSpace = find(' ',$feature.ADDRESS,0)&lt;BR /&gt;var strCount = count($feature.ADDRESS)&lt;BR /&gt;var strDiff = strCount - firstSpace&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;return right($feature.ADDRESS, strDiff)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jul 2019 14:40:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590718#M4010</guid>
      <dc:creator>MarkBockenhauer</dc:creator>
      <dc:date>2019-07-22T14:40:51Z</dc:date>
    </item>
    <item>
      <title>Re: Remove text from a string using python or arcade</title>
      <link>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590719#M4011</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Wow, both the options worked, perfectly, Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jul 2019 14:59:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590719#M4011</guid>
      <dc:creator>SRJS4</dc:creator>
      <dc:date>2019-07-22T14:59:27Z</dc:date>
    </item>
    <item>
      <title>Re: Remove text from a string using python or arcade</title>
      <link>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590720#M4012</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks, Mark. This worked&amp;nbsp;too.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 22 Jul 2019 15:01:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/developers-questions/remove-text-from-a-string-using-python-or-arcade/m-p/590720#M4012</guid>
      <dc:creator>SRJS4</dc:creator>
      <dc:date>2019-07-22T15:01:11Z</dc:date>
    </item>
  </channel>
</rss>

