<?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: Default value for a select_one question type in ArcGIS Survey123 Questions</title>
    <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806814#M12283</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please see the attached file. I was trying to set fields "vision_light" to default "none", kickplate to default "small", bumper to "No", and thickness to "1.75"&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 13 Dec 2018 22:53:41 GMT</pubDate>
    <dc:creator>AdamDaily</dc:creator>
    <dc:date>2018-12-13T22:53:41Z</dc:date>
    <item>
      <title>Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806810#M12279</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you take a value from a select_one question list and set one of those values as the default answer to that question? I feel like I have done this before but it is not working in my current survey. I must be putting this in wrong.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Expl: Choices are Small, Medium, Large, and I want my question to default the answer as "Small"&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 07 Dec 2018 20:00:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806810#M12279</guid>
      <dc:creator>AdamDaily</dc:creator>
      <dc:date>2018-12-07T20:00:45Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806811#M12280</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Adam, the default value for a &lt;EM&gt;select_one&lt;/EM&gt;&amp;nbsp;can be entered in the &lt;STRONG&gt;default&lt;/STRONG&gt; column in your XLSForm. In your example, enter&amp;nbsp;"Small" (without quotes). Please see&amp;nbsp;&lt;A class="link-titled" href="https://doc.arcgis.com/en/survey123/desktop/create-surveys/prepopulateanswers.htm" title="https://doc.arcgis.com/en/survey123/desktop/create-surveys/prepopulateanswers.htm"&gt;Prepopulate answers—Survey123 for ArcGIS | ArcGIS&lt;/A&gt;&amp;nbsp;for more info.&lt;/P&gt;&lt;P&gt;Jim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 09 Dec 2018 23:33:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806811#M12280</guid>
      <dc:creator>Jim-Moore</dc:creator>
      <dc:date>2018-12-09T23:33:41Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806812#M12281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jim for the answer,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I wanted to confirm there wasn't something else I was missing. That is exactly what I tried (also tried with quotes when that didn't work), but the default values are not appearing in Survey Connect testing, or after publishing and downloading my survey. No default field values set for any select_one questions are coming through.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 10 Dec 2018 15:34:19 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806812#M12281</guid>
      <dc:creator>AdamDaily</dc:creator>
      <dc:date>2018-12-10T15:34:19Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806813#M12282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Adam, could you please provide the XLSForm for your survey so I can test? Thanks, Jim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 12 Dec 2018 02:50:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806813#M12282</guid>
      <dc:creator>Jim-Moore</dc:creator>
      <dc:date>2018-12-12T02:50:10Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806814#M12283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please see the attached file. I was trying to set fields "vision_light" to default "none", kickplate to default "small", bumper to "No", and thickness to "1.75"&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 13 Dec 2018 22:53:41 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806814#M12283</guid>
      <dc:creator>AdamDaily</dc:creator>
      <dc:date>2018-12-13T22:53:41Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806815#M12284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Adam, thanks very much for the XLSForm and other survey files. At a quick glance it looks like the pulldata calculation could be superseding the default. I'll take a look and report back.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Dec 2018 06:10:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806815#M12284</guid>
      <dc:creator>Jim-Moore</dc:creator>
      <dc:date>2018-12-14T06:10:20Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806816#M12285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Jim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That is probably what is happening. I didn't think of that because those fields really don't have much data in the dataset to pull from, but I know the pulldata &amp;amp; select_one functions don't play well together so it is likely it won't work with defaults either. Thanks for looking into it.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 14 Dec 2018 18:20:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806816#M12285</guid>
      <dc:creator>AdamDaily</dc:creator>
      <dc:date>2018-12-14T18:20:45Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806817#M12286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Adam&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Just confirming: a default is applied when the survey form first loads or, if in a repeat, when a repeat record is added; a calculation&amp;nbsp;is applied when the values it relies on change. In this case &lt;EM&gt;asset_tag&lt;/EM&gt; is calculated, which in turn applies the calculations&amp;nbsp;for vision_light, kickplate, etc. (overwriting their defaults).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One suggestion would be to modify each calculation so that it results in&amp;nbsp;a default value if the asset_tag is null. For example:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;if(${asset_tag}='','Small',pulldata('features','kick_plate', 'asset_tag', ${asset_tag}))&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Setting a default for 'thickness' in the default column should&amp;nbsp;work as normal as this question does not have a calculation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jim&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Dec 2018 03:19:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806817#M12286</guid>
      <dc:creator>Jim-Moore</dc:creator>
      <dc:date>2018-12-17T03:19:12Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806818#M12287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jim,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem with adding an if statement is there is no field I can use for that to work properly. For example, all of my features have asset_tag values, thus eliminating the default "Small" to ever appear in my kickplate field.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I could use another field to return null, thus&amp;nbsp;making the default "Small" to appear, but then that voids my pulldata function. I end up overwriting existing data I want to keep with inaccurate default data&amp;nbsp;(asset_tag=null so kickplate = Small, but&amp;nbsp;my table shows kickplate =&amp;nbsp;Medium for that feature). The work around is to use 2 fields, 1 text field "kickplate1" using pulldata, and 1 select_one field "kickplate2", only relevant and with default values if "kickplate1" is null. The obvious problem here is having to create 2 fields for capturing each attribute.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I really need to be able to&amp;nbsp;do is say IF "my pulldata function"&amp;nbsp;= null, then activate&amp;nbsp;the default value. And to go 1 step further, to&amp;nbsp;have that statement in&amp;nbsp;a select_one&amp;nbsp;field type. By default, my pulldata functions are already void in any select_one fields. So select_one overwrites pulldata, and pulldata voids default values. So it appears here that my best option is just to eliminate the calculation completely.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 18 Dec 2018 17:34:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806818#M12287</guid>
      <dc:creator>AdamDaily</dc:creator>
      <dc:date>2018-12-18T17:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Default value for a select_one question type</title>
      <link>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806819#M12288</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Adam&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Apologies, I misread your workflow; the thinking was the if&amp;nbsp;statement could be used to set a default for a new asset, i.e. one that doesn't have an existing asset_tag and isn't already in the CSV. I now appreciate this isn't particularly useful in this survey!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regarding this workaround...&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;The work around is to use 2 fields, 1 text field "kickplate1" using pulldata, and 1 select_one field "kickplate2", only relevant and with default values if "kickplate1" is null. The obvious problem here is having to create 2 fields for capturing each attribute.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;...to assist with&amp;nbsp;this, you could use a calculate question with a&amp;nbsp;&lt;STRONG&gt;null&lt;/STRONG&gt; field type (as I see you've already used for several other questions). This would omit the question from the feature service, so you're not storing superfluous data. As you've suggested, put a pulldata in the calculate question. Then use an if statement for the select_one, e.g. if(${calc_kickplate}='','Small',${calc_kickplate}). Providing the values in the CSV exactly match the &lt;EM&gt;choices&lt;/EM&gt; for the corresponding select_one, the correct value will be selected in the form. The user can then modify this selection if required.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Alternatively, would it be feasible to add the default values into the CSV, for all door records that have empty values? Then you could use the pulldata&amp;nbsp;on its own.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 20 Dec 2018 04:17:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-survey123-questions/default-value-for-a-select-one-question-type/m-p/806819#M12288</guid>
      <dc:creator>Jim-Moore</dc:creator>
      <dc:date>2018-12-20T04:17:39Z</dc:date>
    </item>
  </channel>
</rss>

