<?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: Tasks - DataSource XML element - defaultValue parameter bug? in SAS Studio</title>
    <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555323#M7492</link>
    <description>&lt;P&gt;No problem!&amp;nbsp; I'm glad to help and I'm glad that the workaround will work for you for the time being.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-Brian&lt;/P&gt;</description>
    <pubDate>Wed, 01 May 2019 11:11:53 GMT</pubDate>
    <dc:creator>BrianGaines</dc:creator>
    <dc:date>2019-05-01T11:11:53Z</dc:date>
    <item>
      <title>Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555039#M7485</link>
      <description>&lt;P&gt;I'm having problems with the DataSource tag in the task I'm building.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Specifically the issue is with the&amp;nbsp;&lt;STRONG&gt;defaultValue&amp;nbsp;&lt;/STRONG&gt;parameter. &lt;A href="https://go.documentation.sas.com/?docsetId=webeditordg&amp;amp;docsetTarget=n11paravw17avdn1teoj9r7i7fv2.htm&amp;amp;docsetVersion=3.8&amp;amp;locale=en" target="_self"&gt;This&lt;/A&gt; documentation says I can use that parameter to assign a default Data source, however when I try it just doesn't work. Strangely the documentation says that passing in a blank string will force the user to choose a Data Source, and that does indeed work. Specifying one however just brings up the most recent Data Source.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My XML looks like this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&amp;lt;DataSources&amp;gt;	
	&amp;lt;DataSource name="DATASOURCE" defaultValue="SASHELP.FISH" where="true"&amp;gt;
	     &amp;lt;Roles&amp;gt;
	     &amp;lt;/Roles&amp;gt;
	&amp;lt;/DataSource&amp;gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Have I made a mistake or is this a known problem?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2019 14:10:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555039#M7485</guid>
      <dc:creator>jamesBFD</dc:creator>
      <dc:date>2019-04-30T14:10:25Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555096#M7487</link>
      <description>Also seems like defaultValue doesn't work for the Roles tag either? Certainly it isn't for me.</description>
      <pubDate>Tue, 30 Apr 2019 15:48:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555096#M7487</guid>
      <dc:creator>jamesBFD</dc:creator>
      <dc:date>2019-04-30T15:48:32Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555252#M7488</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/272348"&gt;@jamesBFD&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you please tell me which version of SAS Studio you are using?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-Brian&lt;/P&gt;</description>
      <pubDate>Tue, 30 Apr 2019 23:48:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555252#M7488</guid>
      <dc:creator>BrianGaines</dc:creator>
      <dc:date>2019-04-30T23:48:38Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555292#M7489</link>
      <description>&lt;P&gt;We're running 3.6 Enterprise Edition.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;</description>
      <pubDate>Wed, 01 May 2019 07:27:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555292#M7489</guid>
      <dc:creator>jamesBFD</dc:creator>
      <dc:date>2019-05-01T07:27:40Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555320#M7490</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/272348"&gt;@jamesBFD&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks for the information.&amp;nbsp; The defaultValue attribute/parameter was added to the DataSource and Role controls in SAS Studio 3.8.&amp;nbsp; As you noted, this attribute is included in the documentation for SAS Studio 3.8, but if you look at the documentation for &lt;A href="https://go.documentation.sas.com/?docsetId=webeditordg&amp;amp;docsetTarget=n11paravw17avdn1teoj9r7i7fv2.htm&amp;amp;docsetVersion=3.7&amp;amp;locale=en" target="_self"&gt;SAS Studio 3.7&lt;/A&gt; or &lt;A href="https://go.documentation.sas.com/?docsetId=webeditordg&amp;amp;docsetTarget=n11paravw17avdn1teoj9r7i7fv2.htm&amp;amp;docsetVersion=3.6&amp;amp;locale=en" target="_self"&gt;SAS Studio 3.6&lt;/A&gt;, you see that it is not listed or available.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If upgrading to SAS Studio 3.8 is not an option, then a workaround would be to create/compile your task, make the selections for the DataSource and Roles that you want to be the defaults, and then save the task as a .CTK file.&amp;nbsp; Then, when the .CTK&amp;nbsp;task file is opened again (which can be done by right clicking on the .CTK file in the Server Files and Folders section and adding it to "My Tasks"), it will remember the selections you made for DataSource and Roles (and any other selections you made), so effectively you would have default values.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does that make sense?&amp;nbsp; Will that work for you?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-Brian&lt;/P&gt;</description>
      <pubDate>Wed, 01 May 2019 11:08:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555320#M7490</guid>
      <dc:creator>BrianGaines</dc:creator>
      <dc:date>2019-05-01T11:08:45Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555322#M7491</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159490"&gt;@BrianGaines&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks for the reply and solution.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;That makes sense about why it's in that documentation and not working for me. I'd figured out the workaround by inspecting the &amp;lt;TemplateValues&amp;gt; tag code that was being generated when I saved CTK files. I'll look into upgrading Studio but will use the workaround for now.&lt;/P&gt;</description>
      <pubDate>Wed, 01 May 2019 11:06:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555322#M7491</guid>
      <dc:creator>jamesBFD</dc:creator>
      <dc:date>2019-05-01T11:06:11Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555323#M7492</link>
      <description>&lt;P&gt;No problem!&amp;nbsp; I'm glad to help and I'm glad that the workaround will work for you for the time being.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-Brian&lt;/P&gt;</description>
      <pubDate>Wed, 01 May 2019 11:11:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/555323#M7492</guid>
      <dc:creator>BrianGaines</dc:creator>
      <dc:date>2019-05-01T11:11:53Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/657914#M9220</link>
      <description>Sorry to necro this thread, but I was looking to do something similar today, and noticed that the documentation for 3.8 (linked in OP) no longer references defaultValue in data sources (and I have 3.8 and it doesn't work for me).  &lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/159490"&gt;@BrianGaines&lt;/a&gt; - do you know if this was removed from a later update to 3.8, and if so if it will come back at some point?  The workaround you mention is okay, but ideally we'd have the ability to set it directly...  thanks!</description>
      <pubDate>Fri, 12 Jun 2020 06:01:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/657914#M9220</guid>
      <dc:creator>snoopy369</dc:creator>
      <dc:date>2020-06-12T06:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: Tasks - DataSource XML element - defaultValue parameter bug?</title>
      <link>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/658398#M9223</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/46466"&gt;@snoopy369&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;No worries at all about bringing this thread back to life.&amp;nbsp; &amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I looked into this and, from what I can tell, the defaultValue attribute for a DataSource element actually was first introduced in SAS Studio 5.1 and not SAS Studio 3.8.&amp;nbsp; I believe its inclusion in the SAS Studio 3.8 documentation when James &amp;amp; I originally looked at it was a mistake,&amp;nbsp;which is why it has since been removed from the documentation.&amp;nbsp; &amp;nbsp;At the time, I just didn't actually verify that it worked in that version.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I did just try to use it in SAS Studio 3.8 and it also did not work for me, but it does work in SAS Studio 5.1.&amp;nbsp; So unfortunately, the workaround I mentioned previously is still the only way to deal with it in SAS Studio 3.8 that I am aware of.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hopefully this information is helpful!&amp;nbsp; Please post again if you have any additional task writing questions.&amp;nbsp; Speaking of which, this is a shameless plug, but for this year's SAS Global Forum I wrote &lt;A href="https://www.sas.com/content/dam/SAS/support/en/sas-global-forum-proceedings/2020/4376-2020.pdf" target="_self"&gt;a paper on custom task writing&lt;/A&gt;.&amp;nbsp; The focus of the paper is on writing custom tasks that generate CASL code, but I believe most of the tips and information in the paper are applicable to custom task writing in general.&amp;nbsp; I just wanted to bring it to your attention in case the paper is useful.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;-Brian&lt;/P&gt;</description>
      <pubDate>Sun, 14 Jun 2020 19:51:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/Tasks-DataSource-XML-element-defaultValue-parameter-bug/m-p/658398#M9223</guid>
      <dc:creator>BrianGaines</dc:creator>
      <dc:date>2020-06-14T19:51:28Z</dc:date>
    </item>
  </channel>
</rss>

