<?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:  Calculate (plus) multiple fields  in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101690#M5928</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You cannot add Null values with other values.&amp;nbsp; See &lt;A href="http://gis.stackexchange.com/questions/62609/calculating-a-field-in-which-null-values-may-be-present"&gt;Fezter's answer to this post&lt;/A&gt; for a Python method you should be able to adapt to your problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 23 Nov 2015 16:29:36 GMT</pubDate>
    <dc:creator>RichardFairhurst</dc:creator>
    <dc:date>2015-11-23T16:29:36Z</dc:date>
    <item>
      <title>Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101686#M5924</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have problems to calculate (plus) multiple fields in armap. It is normal? any solution?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Nov 2015 15:33:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101686#M5924</guid>
      <dc:creator>CarlosHernandez8</dc:creator>
      <dc:date>2015-11-23T15:33:39Z</dc:date>
    </item>
    <item>
      <title>Re:  Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101687#M5925</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Perhaps you could be a little more specific and provide details of what you are trying to accomplish.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Nov 2015 15:43:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101687#M5925</guid>
      <dc:creator>JoeBorgione</dc:creator>
      <dc:date>2015-11-23T15:43:36Z</dc:date>
    </item>
    <item>
      <title>Re:  Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101688#M5926</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Post the calculation you used.&amp;nbsp; Did you build the expression using the expression builder field list?&amp;nbsp; Are you sure all of the fields are Double, Float, Long or Short fields?&amp;nbsp; Is the output field the correct type to hold the addition result (typically you should use either a Double or a Long output field).&amp;nbsp; Are there Null values in the fields you are adding together?&amp;nbsp; Is the data source a shapefile/dbf file or a geodatabase feature class/table.&amp;nbsp; Is it an SDE database?&amp;nbsp; What version of ArcMap are you using?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Nov 2015 15:46:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101688#M5926</guid>
      <dc:creator>RichardFairhurst</dc:creator>
      <dc:date>2015-11-23T15:46:42Z</dc:date>
    </item>
    <item>
      <title>Re:  Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101689#M5927</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi thanks for answering,&lt;/P&gt;&lt;P&gt;all fields are double,&lt;/P&gt;&lt;P&gt;the output field is double,&lt;/P&gt;&lt;P&gt;there are null values in the fields,&lt;/P&gt;&lt;P&gt;I'm doing it on a feature class (geodatabase)&lt;/P&gt;&lt;P&gt;armap version 10.3&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Calculo:&lt;/P&gt;&lt;P&gt;[PSB_01_V_AÑO]+ [PSB_05_V_AÑO]+ [PSB_03_V_AÑO]+ [PCC_01_V_AÑO]+ [PCC_02_V_AÑO]+ [PCC_04_V_AÑO]+ [PCC_05_V_AÑO]+ [PAM_01_V_AÑO]+ [PAM_02_V_AÑO]+ [PAM_03_V_AÑO]+ [PCE_01_V_AÑO]+ [PCE_02_V_AÑO]+ [PCE_03_V_AÑO]+ [PCE_04_V_AÑO]+ [PCE_05_V_AÑO]+ [PCE_07_V_AÑO]+ [PRE_01_V_AÑO]+ [PRE_02_V_AÑO]+ [PRE_03_V_AÑO]+ [PSP_01_V_AÑO]+ [PSP_02_V_AÑO]+ [PDSP_01_V_AÑO]+ [PDSP_2_V_AÑO]+ [PDSP_3_V_AÑO]+ [PFPS_2_V_AÑO]+ [PFPS_3_V_AÑO]+ [PFPS_1Y4_V_AÑO]&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Nov 2015 16:18:32 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101689#M5927</guid>
      <dc:creator>CarlosHernandez8</dc:creator>
      <dc:date>2015-11-23T16:18:32Z</dc:date>
    </item>
    <item>
      <title>Re:  Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101690#M5928</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You cannot add Null values with other values.&amp;nbsp; See &lt;A href="http://gis.stackexchange.com/questions/62609/calculating-a-field-in-which-null-values-may-be-present"&gt;Fezter's answer to this post&lt;/A&gt; for a Python method you should be able to adapt to your problem.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Nov 2015 16:29:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101690#M5928</guid>
      <dc:creator>RichardFairhurst</dc:creator>
      <dc:date>2015-11-23T16:29:36Z</dc:date>
    </item>
    <item>
      <title>Re:  Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101691#M5929</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As &lt;A href="https://community.esri.com/migrated-users/4811" target="_blank"&gt;Richard Fairhurst&lt;/A&gt;​ indicates, you can get as this with a fairly compact Python code block:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;def calc(*args):
&amp;nbsp; return sum(i for i in args if i is not None) # loop through all arguments in function, adding if not 'None' (i.e. null)&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Your expression would be something like below (listing all desired candidate fields):&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;calc (!Field1!, !Field2!, ..., !Fieldn!)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 06:17:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101691#M5929</guid>
      <dc:creator>DarrenWiens2</dc:creator>
      <dc:date>2021-12-11T06:17:23Z</dc:date>
    </item>
    <item>
      <title>Re:  Calculate (plus) multiple fields</title>
      <link>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101692#M5930</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Or as documented in this link &lt;A href="https://community.esri.com/migration-blogpost/55265"&gt;Before I forget ... # 18 ... Those pesky &amp;amp;lt;null&amp;amp;gt; things...&lt;/A&gt; &lt;/P&gt;&lt;P&gt;for a pythonic approach&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 23 Nov 2015 17:44:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/calculate-plus-multiple-fields/m-p/101692#M5930</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2015-11-23T17:44:01Z</dc:date>
    </item>
  </channel>
</rss>

