<?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>Process Variable not getting assigned with DSE</title><link>https://community.appian.com/discussions/f/process/18322/process-variable-not-getting-assigned-with-dse</link><description>I have a rule to fetch DSE from database. Debugged and works fine. 
 In my process model, I&amp;#39;m using pkId to lookup data using my rule and then assigning it to a process variable. Unfortunately my process variable is not getting assigned. When I debug</description><dc:language>en-US</dc:language><generator>Telligent Community 12</generator><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72204?ContentTypeID=1</link><pubDate>Wed, 19 Feb 2020 14:37:51 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:de513466-0aae-4dda-ab77-924ea2ad8d28</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;No prob - sorry if it&amp;#39;s a little frustrating at certain points, I&amp;#39;ve been there.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72203?ContentTypeID=1</link><pubDate>Wed, 19 Feb 2020 14:32:55 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:3988f5ee-07cd-4a17-86df-0bf662a59d7b</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Okay, the definition of casting then is &amp;quot;if I want to assign two CDTs to each other and they contain same properties, it is convenient&amp;quot;. It then also explains why Appian didn&amp;#39;t throw an error. VERY important learning for me. I thank you again for your patience and persistence with me.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72192?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 23:55:49 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c285e8c0-8543-4ccc-aa83-50958d3ad728</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;Not sure what to tell ya then. &amp;nbsp;Type casting will attempt to work between any two complex types as far as I know and will use any fields named the same. &amp;nbsp;Particularly because it would let me cast a type containing &amp;quot;name&amp;quot;, &amp;quot;id&amp;quot; and a hundred other fields, for example into a special CDT containing just &amp;quot;name&amp;quot; and &amp;quot;id&amp;quot;. &amp;nbsp;But if there are no common properties between the two types, then the resulting cast operation will result in blank data, such as what you were seeing. &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72191?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 23:49:51 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:8bef9ecf-d9f1-493d-b38f-732f177fca3d</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Okay, forgive me but that seems a bit lame. Casting a &amp;quot;Date&amp;quot; to a &amp;quot;Text&amp;quot; or vice versa I can understand. Date can be converted to Text with a tostring operation. Text can be converted to Date assuming the Text carried date in some valid format, e.g. MM/dd/yyyy.&lt;/p&gt;
&lt;p&gt;On what planet would a DataSet with multiple attributes when cast to a type of CDT not throw error? It would be one thing if it actually worked, because Appian would smartly assume assignment is to a CDT so let&amp;#39;s see if &amp;quot;data&amp;quot; attribute of the DataSet is of that type. But it didn&amp;#39;t do that. which is fine, but then not throwing error?&lt;/p&gt;
&lt;p&gt;I may be new to Appian, but I am finding it very hard to buy this logic. If there&amp;#39;s some article explaining how Appian implemented casting behavior I would appreciate it. Else I&amp;#39;m going to have to keep writing complicated SAIL expressions. And then &amp;quot;low code&amp;quot; goes out the window.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72190?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 23:44:51 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:8cf713cb-f749-4995-8e70-749e371e20b4</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;To get the data from the data subset, you add &amp;quot;.data&amp;quot; either after the query entity expression, or after the expression rule where you call it. &amp;nbsp;Note that I talked about this and also put it into one of my more recent code examples above.&lt;/p&gt;
&lt;p&gt;Appian doesn&amp;#39;t give an error because it freely allows types to be cast as other types, and it has no inherent way of knowing whether you&amp;#39;re trying to do a valid typecasting or not. &lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72189?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 23:41:25 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:973eec76-08d2-46dc-8ecd-71c141abfc83</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Sorry if I&amp;#39;m being dense. I need some SAIL expression I&amp;#39;m thinking to extract the Vehicle. If you showed that somewhere, I&amp;#39;m missing it.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;EDIT: Doh! I see it now. follow expression with &amp;quot;.data&amp;quot;.&lt;/p&gt;
&lt;p&gt;BUT Question No 1. How can Appian not throw up when I try to assign a DataSet to a Vehicle? How is there no error generated? If It did, my mistake would have been so obvious. Am I suppose to configure Exception tab to see error?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72188?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 23:39:50 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d748ba40-8237-4a9a-aa2a-eb304c40ff1b</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;This is what I was attempting to show you in several of my previous replies...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72187?ContentTypeID=1</link><pubDate>Tue, 18 Feb 2020 23:36:27 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:adb83dc0-2fce-46f8-b76d-87fd81cd67f3</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Okay so I figured out my problem. I don&amp;#39;t think the instructions in the tutorial are clear.&lt;/p&gt;
&lt;p&gt;When I have a Query Expression Rule, what I get back is an object of type DataSubset.&lt;/p&gt;
&lt;p&gt;When I&amp;#39;m asking Script Task Custom Output to save the results to my CDT, it does not work. My&amp;nbsp;first question is why is Appian not throwing an error when I&amp;#39;m trying to assign a &amp;#39;DataSubset&amp;#39; to a &amp;#39;Vehicle&amp;#39;? Pressing question is how do I extract the 1 Vehicle instance in my Dataset?&lt;/p&gt;
&lt;p&gt;What I did was typename(typeof(rule!VFM_getVehicleById(pv!vehicleId))) to realize I&amp;quot;m getting a Dataset back and not a Vehicle. I was blindly following screenshot in the tutorial to my detriment.&lt;/p&gt;
&lt;p&gt;So right now I&amp;#39;m trying to assign the results of expression rule!VFM_getVehicleById(pv!vehicleId) to pv!vehicle. I need to modify the expression to yield the embedded CDT. Can anyone help?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72122?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 18:08:05 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:d0e940ee-bc3b-45e4-b6a6-d49c09ad2728</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;The frustrating part I&amp;#39;ve found about Appian, is that things stop working at random for no reason. Just after I made the change you told me, it worked twice and then again without me changing anything, it stopped working. Most of the times unpublishing / publishing application solves the issue, but not today.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The process model picked up the modification to the getVehicleById(), then I removed the debut TEXT pv and now it will not pickup the change.&lt;/p&gt;
&lt;p&gt;It&amp;#39;s the weekend...Anyways, thanks again for your help. Learned something today.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72121?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 17:53:18 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:bc2b6c7f-6394-49c2-9922-259debdd6810</guid><dc:creator>Mike Schmitt</dc:creator><description>[quote userid="42721" url="~/discussions/f/process/18322/process-variable-not-getting-assigned-with-dse/72120"]Is it possible for the Query Editor to generate the code I now see I&amp;#39;m missing?[/quote]
&lt;p&gt;I don&amp;#39;t have much experience using the (relatively new) Query Editor as I&amp;#39;m used to just writing any necessary query entities by hand.&amp;nbsp; In general my suggested approach for using it would pretty much always be to use it only to quickly establish a basic query that works, and then tweak it per your needs in the Expression Rule editor (and also test it there, etc).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72120?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 17:49:32 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:95955712-64a6-40b6-9f37-d108e843b192</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Thank you for the Code Box tip!&lt;/p&gt;
&lt;p&gt;Is it possible for the Query Editor to generate the code I now see I&amp;#39;m missing? I was imagining Appian automagically inserts it when query is run. Obviously I see I&amp;#39;m wrong now.&lt;/p&gt;
&lt;p&gt;I needed to include the rule input against the filter for the generated SAIL expression to include it! Doh!&lt;/p&gt;
&lt;p&gt;On to next problem.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72119?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 17:16:55 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:3e284031-8d26-4a7d-8c1e-28690f8b1432</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;BTW, when you post code, you should consider using a &lt;em&gt;Code Box&lt;/em&gt;, by hitting &amp;quot;Insert&amp;quot; -&amp;gt; &amp;quot;Insert Code&amp;quot;.&amp;nbsp; This will preserve formatting/indenation, and give a nice size-constricted display box to keep the comment from wasting an undue amount of space within the conversation.&lt;/p&gt;
&lt;p&gt;For instance, here&amp;#39;s the same code as above, except I&amp;#39;ve added the filter value (and set the applyWhen parameter as well).&amp;nbsp; I used &amp;quot;ri!inputId&amp;quot; but you can use whatever your rule input is called.&lt;/p&gt;
&lt;p&gt;&lt;pre class="ui-code" data-mode="java"&gt;a!queryEntity(
  entity: cons!VEHICLE_DSE_VFM,
  query: a!query(
    logicalExpression: a!queryLogicalExpression(
      operator: &amp;quot;AND&amp;quot;,
      filters: {
        a!queryFilter(
          field: &amp;quot;id&amp;quot;,
          operator: &amp;quot;=&amp;quot;,
          value: ri!inputId,
          applyWhen: not(isnull(ri!inputId))
        )
      },
      ignoreFiltersWithEmptyValues: true
    ),
    pagingInfo: a!pagingInfo(
      startIndex: 1,
      batchSize: 50
    )
  ),
  fetchTotalCount: false
)&lt;/pre&gt;&lt;/p&gt;
&lt;p&gt;Edited to add:&amp;nbsp; I also notice you&amp;#39;re not referencing the &amp;quot;.data&amp;quot; of the rule&amp;#39;s dataSubset output (as I suspected earlier, which is why I was asking you to post the sample output of this rule to confirm).&amp;nbsp; So, before you can expect get any data properly saving into your in-process PV, you will need to add &amp;quot;.data&amp;quot; either within the expression rule (at the very end of the &lt;em&gt;a!queryEntity()&lt;/em&gt; call), or in the process model itself after the expression rule call.&amp;nbsp; I.E.,&lt;/p&gt;
&lt;pre&gt;&lt;span&gt;rule!VFM_getVehicleById(inputId: pv!updateId).data&lt;/span&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72118?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 17:12:33 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:de567404-ced9-47ee-96ca-c7937451939c</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;Well, the first thing I see is that your queryFilter has nothing being passed in for the &amp;quot;value&amp;quot; parameter - you&amp;#39;d need to at least add that, or else it wouldn&amp;#39;t do anything.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72117?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 17:09:38 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:43f7ac7f-4a1a-4d6e-b1a7-509a92870766</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;I feel like an idiot. I said it was working. Yeah...working INCORRECTLY!&lt;/p&gt;
&lt;p&gt;My filter is not getting applied to return only 1 Record with Id = 4. I do have filter defined with &amp;quot;Always&amp;quot;. Problem is whether I pass argument or not, always ALL records are getting returned. So obviously on my Record Display when I&amp;#39;m calling rule without arguments it returns all and I say &amp;quot;it is working&amp;quot;, but when I pass only parameter = 4, it STILL returns everything when executing in the Process Model, which is obviously the problem.&lt;/p&gt;
&lt;p&gt;Code is below. If you can kindly spot where I have (obviously) messed up&lt;/p&gt;
&lt;p&gt;a!queryEntity(&lt;br /&gt; entity: cons!VEHICLE_DSE_VFM,&lt;br /&gt; query: a!query(&lt;br /&gt; logicalExpression: a!queryLogicalExpression(&lt;br /&gt; operator: &amp;quot;AND&amp;quot;,&lt;br /&gt; filters: {&lt;br /&gt; a!queryFilter(&lt;br /&gt; field: &amp;quot;id&amp;quot;,&lt;br /&gt; operator: &amp;quot;=&amp;quot;&lt;br /&gt; )&lt;br /&gt; },&lt;br /&gt; ignoreFiltersWithEmptyValues: true&lt;br /&gt; ),&lt;br /&gt; pagingInfo: a!pagingInfo(&lt;br /&gt; startIndex: 1,&lt;br /&gt; batchSize: 50&lt;br /&gt; )&lt;br /&gt; ),&lt;br /&gt; fetchTotalCount: false&lt;br /&gt;)&lt;/p&gt;
&lt;p&gt;PS - In the Query Editor, when I pass argument it DOES return only 1 row, but the generated SAIL query does not work when used within Process Model.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72116?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:59:55 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:75c0fe89-430a-452d-bb28-8cee3b66f53b</guid><dc:creator>Mike Schmitt</dc:creator><description>[quote userid="42721" url="~/discussions/f/process/18322/process-variable-not-getting-assigned-with-dse/72114"]When I said I know for a fact my VFM_getVehicleById() works it is indeed because I tested it independently by passing 4 as parameter.[/quote]
&lt;p&gt;I believe you that it works, in general, but that&amp;#39;s not the reason I&amp;#39;m asking.&amp;nbsp; I want to know what the exact output is, since there are a few different possible mistakes I&amp;#39;ve commonly seen (and made myself a few times) that I want to verify against -- which I&amp;#39;d have to see the exact output of the rule in order to be sure of.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72114?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:51:06 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:1fb4becb-4c28-4a34-923f-ee42136f8175</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Okay, sorry if I&amp;#39;m bad at replying. When I said I know for a fact my VFM_getVehicleById() works it is indeed because I tested it independently by passing 4 as parameter. It returns all the field properties as it is supposed to just fine.&lt;/p&gt;
&lt;p&gt;I will try the TEXT pv trick you suggest and reply back ASAP editing this post. Thank you very much for your patience!&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72113?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:43:28 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:c23e6ef7-05fe-4573-82ae-c874121f1a0b</guid><dc:creator>Mike Schmitt</dc:creator><description>[quote userid="42721" url="~/discussions/f/process/18322/process-variable-not-getting-assigned-with-dse/72112"]Is there a way to debug/trap data returned from the fetch rule *before* Appian populates it into vehicle pv? [/quote]
&lt;p&gt;Yes - as I said before, &lt;em&gt;&lt;strong&gt;open&amp;nbsp;&lt;/strong&gt;&lt;/em&gt;&lt;span&gt;&lt;strong&gt;VFM_getVehicleById&lt;/strong&gt;&lt;em&gt;&lt;strong&gt; in the Expression Rule editor&lt;/strong&gt;&lt;/em&gt;, enter your id input (4), and click &amp;quot;Test Rule&amp;quot;.&amp;nbsp; Have you done this already?&amp;nbsp; And if so, what is the&amp;nbsp;&lt;em&gt;exact&lt;/em&gt; result?&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;If you want to &amp;quot;trap&amp;quot; the rule&amp;#39;s output within the process model only (i.e. you think it&amp;#39;s already working when viewed from the expression rule editor), you can create a new (temporary) &lt;em&gt;&lt;strong&gt;TEXT&lt;/strong&gt;&lt;/em&gt; PV, and save the same query result (wrapped in the&amp;nbsp;&lt;em&gt;toString()&lt;/em&gt; function) into it.&amp;nbsp; This will generally tell you whether any data at all is being returned from the query when the process is run, for instance if it&amp;#39;s something that&amp;#39;s returning data but not matching the CDT type of the original target PV.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72112?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:38:04 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:f7f73ace-3aac-4ffa-a3be-4122c0e53107</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Okay...So this is what I did.&lt;/p&gt;
&lt;p&gt;Instead of setting my updateId process variable to 0, I set it explicitly to 4 (which I know is a good id for a vehicle in database)&lt;/p&gt;
&lt;p&gt;I started process for debugging. I see updateid as 4 on Process Details VAriables tab. So eliminated Record Action not passing data possibility.&lt;/p&gt;
&lt;p&gt;I refreshed to move past the Script Task and land at the User Input Task. By this point, my vehicle pv should have been populated. When I look at my Variables tab again I can see it is *not* populated.&lt;/p&gt;
&lt;p&gt;So I can tell you 4 is a valid Id. I can tell you getVehicleById(4) should not fail. I have tested this and it works. I&amp;#39;ve removed any doubt 4 was not getting passed from Record Action to Process instance. BUT I cannot tell if when my rule was called to fetch the data whether it worked or not, because the only way to check is looking at what&amp;#39;s in vehicle pv.&lt;/p&gt;
&lt;p&gt;Is there a way to debug/trap data returned from the fetch rule *before* Appian populates it into vehicle pv? That would tell me once and for all for whatever reason my fetch rule works everywhere else *but* not from within my Script Task.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72111?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:29:00 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:7412082b-d2d0-4488-a4c9-c0ad5634f515</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;Thanks for clarifying your process model configuration -- that sounds right to me.&amp;nbsp; But what I&amp;#39;m actually asking for is the exact output of the rule itself.&amp;nbsp; When you open VFM_getVehicleById, and run it, what do you see in the &amp;quot;Test Output&amp;quot; section?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72110?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:26:35 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:225e17f5-5c5b-419b-b4d4-06dd14f7d991</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Unfortunately &amp;quot;Security&amp;quot; at my sight is blocking me from pasting screen shots at this time. If/When I&amp;#39;m able I will post the screenshot.&amp;nbsp; If you can visualize with me. It is exactly like in the Appian tutorial lesson.&lt;/p&gt;
&lt;p&gt;On the Data Output Tab,&lt;/p&gt;
&lt;p&gt;On the left, I have&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Custom Outputs&lt;/p&gt;
&lt;p&gt;rule!VFM_getVehicleById(pv!updateId)&lt;/p&gt;
&lt;p&gt;On the right, I have Expression Properties...&lt;/p&gt;
&lt;p&gt;Expression: rule!VFM_getVehicleById(pv!updateId)&lt;/p&gt;
&lt;p&gt;Operator: is stored as&lt;/p&gt;
&lt;p&gt;Target: vehicle&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72109?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:21:23 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:b296cdf0-9663-444e-84fa-fc02e5d6cf94</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;Sorry, then I misunderstood what you were referring to when you said your PV was &amp;quot;data store entity&amp;quot; type.&lt;/p&gt;
&lt;p&gt;Can you confirm / post a screenshot of the output of rule!VFM_getVehicleById() when passing in an example id, within the expression rule editor?&amp;nbsp; For example, sometimes people forget to reference the &amp;quot;.data&amp;quot; in the query entity output, to get the CDT type data itself as opposed to the DataSubset returned by default by a!queryEntity.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72108?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 15:18:25 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:97a1bd43-baf6-4315-a607-38790c509d6c</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Yes of course. See, the pv is indeed of the correct CDT type, because only then am I able to populate data on UserInputTask form and save to Database through the DSE. All this works perfectly.&lt;/p&gt;
&lt;p&gt;To boil it down to code for the Custom Output configured on Data-&amp;gt;Output tab of my Script Task which I introduced prior to the UserINputTask&lt;/p&gt;
&lt;p&gt;rule!VFM_getVehicleById(updateId) /* where updateId = 4 (say) based on record selected */&lt;/p&gt;
&lt;p&gt;&amp;quot;save into&amp;quot; vehicle, where vehicle pv is of type CDT. I&amp;#39;m not typing anything, but selecting from UI so I know I&amp;#39;m doing this correctly.&lt;/p&gt;
&lt;p&gt;Basically my Script Task Custom Output configuration is not working. I&amp;#39;m not able to tell if for any reason VFM_getVehicleById() is failing - it really can&amp;#39;t because I can see it is getting a valid &amp;quot;updateId&amp;quot; value passed in - or Appian is not saving CDT instance returned into pv!vehicle.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72107?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 14:53:48 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:e1cf2fa5-f12b-4a57-8942-d32135af7be4</guid><dc:creator>Mike Schmitt</dc:creator><description>&lt;p&gt;If you&amp;#39;re trying to save the CDT data attained from the query result, into a PV, you&amp;#39;ll need to make the PV a CDT of that type, and not the &amp;quot;data store entity&amp;quot; type (assuming i understand correctly that that&amp;#39;s your PV type).&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72106?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 14:14:45 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:06e05a40-6657-4947-8e75-cf96fc5126f5</guid><dc:creator>appianfreak</dc:creator><description>&lt;p&gt;Yes, of course.&lt;/p&gt;
&lt;p&gt;Sorry, I was avoiding being long winded. Basically I&amp;#39;m going through the Vehicle Fleet tutorial. I created my process model to add new Vehicle. Then I wanted to develop Record Action to Update it. So I modified the process, introduced process variable input to take vehicle Id and then added script task to read Vehicle before feeding my UserInput Task. When I saw the User Input task form show up empty and found out that my pv for Vehicle DSE is not getting assigned. My rule for getVehicleById() I know works because otherwise nothing else would have worked and id is also getting passed to the process from my Record &amp;quot;update&amp;quot; action.&lt;/p&gt;
&lt;p&gt;Hope this clarifies. I realize this is basic, but just can&amp;#39;t get it to work.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Process Variable not getting assigned with DSE</title><link>https://community.appian.com/thread/72105?ContentTypeID=1</link><pubDate>Fri, 14 Feb 2020 13:33:50 GMT</pubDate><guid isPermaLink="false">d3a83456-d57b-489c-a84c-4e8267bb592a:cd0868b8-5bfb-46bf-8149-78349811e014</guid><dc:creator>Mike Schmitt</dc:creator><description>[quote userid="42721" url="~/discussions/f/process/18322/process-variable-not-getting-assigned-with-dse"]my entity object is empty.[/quote]
&lt;p&gt;Just to confirm -- what type is the process variable in question?&amp;nbsp; It almost sounds like you have a PV of type &amp;quot;data store entity&amp;quot;...&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>