<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://community.appian.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/discussions/f/data/20621/how-to-cast-a-cdt-into-an-new-local-variable-updating-a-field</link><description>Hi, 
 I&amp;#39;m trying to save into a local variable some data retrieved from an ER. But I would need to update some fields before to store it into my new local var. 
 Is there any way to do it ? 
 With the code below I can either cast the data, either create</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80404?ContentTypeID=1</link><pubDate>Fri, 19 Mar 2021 16:16:38 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:f50594c7-70c0-4101-b611-4d49c764b61a</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;Very interesting...&lt;br /&gt;thank you for your feedback.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80402?ContentTypeID=1</link><pubDate>Fri, 19 Mar 2021 14:11:47 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:183e8294-e4f2-42bd-a4ce-c3091a2ad157</guid><dc:creator>Mike Schmitt</dc:creator><description>[quote userid="50421" url="~/discussions/f/data/20621/how-to-cast-a-cdt-into-an-new-local-variable-updating-a-field/80392#80392"]if you would not have this plugin, how would you do ?[/quote]
&lt;p&gt;It would be a total pain in the butt and require unreasonable workarounds.&amp;nbsp; In the old days before this plug-in was stable, we just had to be very careful to structure our implementations in such a way that we didn&amp;#39;t end up needing it (which is also a pain in the butt).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80394?ContentTypeID=1</link><pubDate>Fri, 19 Mar 2021 07:30:13 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:f9a2f6b4-3528-41eb-9670-b8bc7bd0f518</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;Thanks a lot for your reply Stefan.&amp;nbsp;Yes of course, that makes sense and we already use it for&amp;nbsp;our customers.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80393?ContentTypeID=1</link><pubDate>Fri, 19 Mar 2021 07:22:11 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:63b4255a-3c96-4a57-b74c-659e43aa437b</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;Using the plugin is the way to go. I am talking to Appian for quite a while to get this function into the product. There is no environment I have ever seen where this is not deployed. In the end, this is what plugins are for and it works pretty well.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80392?ContentTypeID=1</link><pubDate>Fri, 19 Mar 2021 07:12:43 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:b6ea6bcd-4ead-45ee-aaa9-699d707896b6</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;I&amp;#39;m re-sorry Mike, my previous post was sent too quickly (I&amp;#39;ve re-edited my previous post).&lt;/p&gt;
&lt;p&gt;Thank you, all works fine, but I confirm you that the old &amp;quot;cdt&amp;quot; attribute works well, anyway I have to use the new one.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Stefan, thank you very much for your help. &amp;quot;data[1]&amp;quot; saved my life ;-)&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;- A last question, if you would not have this plugin, how would you do ?&lt;/p&gt;
&lt;p&gt;you would enter the 50 fields of the CDT and update the only one value to change ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80381?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 17:52:20 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:a4611b91-1eab-4981-9fd9-c6fdfc12e823</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;oh, also - at the end of your example code you&amp;#39;re only outputting the value of local!vehicle, not of local!vehicleUpdateCdt - so we would expect the output you&amp;#39;re seeing to only be the original and not the updated version.&lt;/p&gt;
&lt;p&gt;Instead your code should look like this:&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="java"&gt;a!localVariables(
  local!vehicle: rule!TST_GetVehiclesWithFilters(
    id: 1
  ).data[1],
  local!vehicleUpdateCDT: updatedictionary(
    dictionary: local!vehicle,
    fieldsAndValues: {
      make: &amp;quot;test2&amp;quot;
    }
  ),
  
  local!vehicleUpdateCDT
)&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80380?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 17:38:55 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:4f71801f-2125-48ed-b338-630213540abb</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;Sorry Mike, it was an error, of course, I&amp;#39;ve tested before with the &amp;quot;dictionary&amp;quot; field name.&lt;/p&gt;
&lt;p&gt;I&amp;nbsp;have edited&amp;nbsp;my previous post.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80379?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 17:23:48 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:7383ce97-b340-484b-b418-014f03c507e9</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;you&amp;#39;re using &amp;quot;&lt;em&gt;&lt;strong&gt;updatedictionary&lt;/strong&gt;&lt;/em&gt;()&amp;quot; but then passing it a property named &amp;quot;&lt;strong&gt;cdt&lt;/strong&gt;&amp;quot; instead of &amp;quot;dictionary&amp;quot;.&amp;nbsp; This would cause it to assume that the input dictionaryis blank, which is approximately what we&amp;#39;re seeing from your output.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80378?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 17:06:16 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d48f7ed5-cd3a-4ed0-8ed5-21ec950bc75e</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;Very good Idea, I did not think about this :-(&lt;/p&gt;
&lt;p&gt;but it still does not work :&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;a!localVariables(
  local!vehicle: rule!TST_GetVehiclesWithFilters(
    id: 1
  ).data[1],
  local!vehicleUpdateCDT: updatedictionary(
    dictionary: local!vehicle,  /* &amp;quot;cdt&amp;quot; atribute works well too */
    fieldsAndValues: {
      make: &amp;quot;test2&amp;quot;
    }
  ),
  local!vehicle /* sorry variable was incorrect --&amp;gt; local!vehicleUpdateCDT! */
)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Here is the result:&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;Dictionary&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;deleted&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;false&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Boolean)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;value&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;20&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Decimal))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;year&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;2022&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;dateacquired&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;null&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Date)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;isavailable&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;true&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Boolean)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;vin&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;model&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;model1&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;make&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;make1&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;id&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;1&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80376?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:55:33 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:aba3bbb2-da83-453d-96f8-105bcddb1214</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;OK. Then you need to drill down like local!vehicle.data[1].&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80375?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:53:30 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:2c5f8419-5980-4132-8dd9-150f645f01f4</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;It contains a only one item DataSubset&amp;nbsp;:&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;List of DataSubset - 1 item&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;DataSubset&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;startIndex&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;1&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;batchSize&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;10&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;sort&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;List of SortInfo - 1 item&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;SortInfo&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;field&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;deleted&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;ascending&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;true&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Boolean)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;totalCount&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;1&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;data&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;List of Dictionary - 1 item&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;Dictionary&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;deleted&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;false&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Boolean)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;value&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;20&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Decimal))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;year&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;2022&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;dateacquired&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;null&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Date)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;isavailable&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;true&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Boolean)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;vin&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;model&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;model1&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;make&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;&amp;quot;make1&amp;quot;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Text)&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;id&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;1&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_key"&gt;identifiers&amp;nbsp;&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;List of Number (Integer) - 1 item&lt;/span&gt;&lt;/span&gt;
&lt;ul class="SelectableTreeNode---componentConfigParam"&gt;&lt;/ul&gt;
&lt;ul class="SelectableTreeNode---nonComponentConfigParam"&gt;
&lt;li class="SelectableTreeNode---selectableTreeNode SelectableTreeNode---leaf SelectableTreeNode---open SelectableTreeNode---last SelectableTreeNode---allow_text_highlighting"&gt;&lt;i class="SelectableTreeNode---icon SelectableTreeNode---openCloseLink"&gt;&lt;/i&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_value"&gt;1&lt;/span&gt;&lt;span class="CollapsibleOutputNode---print_element_type"&gt;(Number (Integer))&lt;/span&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80374?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:40:44 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:4e21a6dc-f28b-4d27-9e2f-0721c2ee9414</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;In this code of yours&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;a!localVariables(
  local!vehicle: rule!TST_GetVehiclesWithFilters(
    id: 1
  ),
  local!vehicleUpdateCDT: updatedictionary(
    dictionary: local!vehicle,
    fieldsAndValues: (
      {
        make: &amp;quot;test2&amp;quot;
      }
    )
  ),

  {
    local!vehicleUpdateCDT
  }
)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;What is the actual content of local!vehicle? Datasubset / single item / list of items?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80373?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:34:10 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:bfb83f31-b04d-4115-8526-78f1f414aa3b</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;yes, this works fine.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80372?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:32:19 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:6ad934af-ce14-4c64-9d6c-17c35df91a8f</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;a!localVariables(
  local!item: {name: &amp;quot;NOT HANS&amp;quot;},
  updatedictionary(
    local!item,
    {
      name: &amp;quot;HANS&amp;quot;
    }
  )
)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Does this work for you?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80371?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:28:13 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:b758b812-978d-4b23-b10d-ca1f62e6b0ce</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;&lt;span&gt;&lt;span class="CollapsibleOutputNode---print_non_value"&gt;My test CDT contains standard data types :&lt;img alt=" " src="/resized-image/__size/320x240/__key/communityserver-discussions-components-files/16/6433.CDT.JPG" /&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80369?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:22:17 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:bbf751f4-f4f2-4c55-b6a0-52692930f42a</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;a!localVariables(
  local!item: rule!SBA_QR_GetConfigurationItemByIdent(1),
  updatedictionary(
    local!item,
    {
      name: &amp;quot;Hans&amp;quot;
    }
  )
)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;My small test. Works a expected for dictionaries, maps and CDTs. How does your CDT look like? There are some quirks with certain data type.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80368?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:16:17 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:e3a85b6c-80d5-4f8e-9001-358602d506fa</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;I&amp;#39;ve already used this plugin with this ({ }), and it has worked well.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;But in my below ER example,&amp;nbsp;it still does not work (according your suggestion).&lt;/p&gt;
&lt;p&gt;Would you see another error ?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80367?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:09:56 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:ab38b461-abbc-4486-8c76-7ddf4d27a336</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;Lines 7-10 should look like&lt;/p&gt;
&lt;p&gt;fieldsAndValues:&amp;nbsp;{&lt;br /&gt; make: &amp;quot;test2&amp;quot;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p&gt;There are to many brackets.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80366?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 16:06:15 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:ef281d3a-b193-4590-bebf-526e582e2950</guid><dc:creator>cedric02</dc:creator><description>&lt;p&gt;Thank you Stefan but I&amp;#39;ve already tested it without success.&lt;/p&gt;
&lt;p&gt;Am I forgetting something ?&amp;nbsp; (the value of the &amp;quot;make&amp;quot; field does not change)&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="text"&gt;a!localVariables(
  local!vehicle: rule!TST_GetVehiclesWithFilters(
    id: 1
  ),
  local!vehicleUpdateCDT: updatedictionary(
    dictionary: local!vehicle,
    fieldsAndValues: (
      {
        make: &amp;quot;test2&amp;quot;
      }
    )
  ),

  {
    local!vehicleUpdateCDT
  }
)
&lt;/pre&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: How to cast a CDT into an new local variable, updating a field ?</title><link>https://community.appian.com/thread/80365?ContentTypeID=1</link><pubDate>Thu, 18 Mar 2021 15:54:39 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:769bc5b3-1823-45fd-8733-dec4c96a33e6</guid><dc:creator>Stefan Helzle</dc:creator><description>&lt;p&gt;This plugin should help&lt;/p&gt;
&lt;p&gt;&lt;a href="https://community.appian.com/b/appmarket/posts/cdt-manipulation"&gt;community.appian.com/.../cdt-manipulation&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>