<?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 Survey 123 complex calculation does not work in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785748#M7058</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a strange phenomenon occuring&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a calculation that used to work, is not being populated anymore.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a decimal field with a calculation. The following works:&lt;/P&gt;&lt;P&gt;${TOTAL_TRANSECT_LENGTH}*${DUB_CM_FOURTH}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The calculation is being performed&amp;nbsp;using fields inside a repeat. the calculated field is outside that repeat.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when i substitute the above eqn for this:&lt;/P&gt;&lt;P&gt;pow(pi(),2)*sqrt(sum(${DUB_CM_FOURTH}))div(8*(sum(${TOTAL_TRANSECT_LENGTH})))*1.64&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it does not work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;These eqns were working before.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i have attached the xlsform used to generate the survey.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 13 Sep 2018 04:33:01 GMT</pubDate>
    <dc:creator>LeeStamm1</dc:creator>
    <dc:date>2018-09-13T04:33:01Z</dc:date>
    <item>
      <title>Survey 123 complex calculation does not work</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785748#M7058</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a strange phenomenon occuring&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a calculation that used to work, is not being populated anymore.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have a decimal field with a calculation. The following works:&lt;/P&gt;&lt;P&gt;${TOTAL_TRANSECT_LENGTH}*${DUB_CM_FOURTH}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The calculation is being performed&amp;nbsp;using fields inside a repeat. the calculated field is outside that repeat.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;when i substitute the above eqn for this:&lt;/P&gt;&lt;P&gt;pow(pi(),2)*sqrt(sum(${DUB_CM_FOURTH}))div(8*(sum(${TOTAL_TRANSECT_LENGTH})))*1.64&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;it does not work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;These eqns were working before.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i have attached the xlsform used to generate the survey.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cheers&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2018 04:33:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785748#M7058</guid>
      <dc:creator>LeeStamm1</dc:creator>
      <dc:date>2018-09-13T04:33:01Z</dc:date>
    </item>
    <item>
      <title>Re: Survey 123 complex calculation does not work</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785749#M7059</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Lee,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are a few issues to address on the form; it looks like you made a few changes that change the behavior&lt;/P&gt;&lt;P&gt;- you have four trisect length fields - where these previously a repeat? &amp;nbsp;The formula you have is using sum() over a question that's not in a repeat - it's not going to return the value properly. &amp;nbsp;removing the sum() will allow the calculation to work&lt;/P&gt;&lt;P&gt;- the calculate questions in the repeat that return numbers (DUB, DUB_CM_SQUARED, DUB_CM_FOURTH) should have the bind::type field set to decimal to ensure that calculations are performed correctly.&lt;/P&gt;&lt;P&gt;- at the beginning of the form, there are 2 hidden questions that appear to have been single choice questions previously. &amp;nbsp;Note that hidden questions default to string - you may want to change this to calculate questions with bind::type of decimal as well&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Sep 2018 18:11:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785749#M7059</guid>
      <dc:creator>JamesTedrick</dc:creator>
      <dc:date>2018-09-13T18:11:39Z</dc:date>
    </item>
    <item>
      <title>Re: Survey 123 complex calculation does not work</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785750#M7060</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi James,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your assistance.&lt;/P&gt;&lt;P&gt;re:&lt;/P&gt;&lt;P&gt;"- you have four trisect length fields - where these previously a repeat? &amp;nbsp;The formula you have is using sum() over a question that's not in a repeat - it's not going to return the value properly. &amp;nbsp;removing the sum() will allow the calculation to work"&lt;/P&gt;&lt;P&gt;I removed the sum and it worked. Thanks.&lt;/P&gt;&lt;P&gt;It was Sum from a previous version of this&amp;nbsp;survey&amp;nbsp;using repeats- my mistake.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;re:&lt;/P&gt;&lt;P&gt;&amp;nbsp;"the calculate questions in the repeat that return numbers (DUB, DUB_CM_SQUARED, DUB_CM_FOURTH) should have the bind::type field set to decimal to ensure that calculations are performed correctly."&lt;/P&gt;&lt;P&gt;Thanks, I changed this at the same time and the calcs work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;re:&lt;/P&gt;&lt;P&gt;"- at the beginning of the form, there are 2 hidden questions that appear to have been single choice questions previously. &amp;nbsp;Note that hidden questions default to string - you may want to change this to calculate questions with bind::type of decimal as well"&lt;/P&gt;&lt;P&gt;Also done. thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS. meant to say that I'm a bargain basement beginner at this. ive only spent a day or two doing this and so far, pretty good.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Sep 2018 02:32:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/survey-123-complex-calculation-does-not-work/m-p/785750#M7060</guid>
      <dc:creator>LeeStamm1</dc:creator>
      <dc:date>2018-09-18T02:32:08Z</dc:date>
    </item>
  </channel>
</rss>

