From: "bbutler@... [vantage]" <vantage@yahoogroups.com>
To: vantage@yahoogroups.com
Sent: Thursday, September 10, 2015 7:22 AM
Subject: [Vantage] E10.0.704: BPM C# Runtime error with query statement
From what I can see through various stackoverflow & MSDN post, LINQ doesn’t like the section:
Jose C Gomez
T: 904.469.1524 mobile
Quis custodiet ipsos custodes?
On Thu, Sep 10, 2015 at 8:00 AM, Ted Koch tkoch77@... [vantage] <vantage@yahoogroups.com> wrote:Â<div> <p></p><div style="color:#000;background-color:#fff;font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:13px;">How is it failing, are you getting an error message when it is triggered?<br><div><span></span></div> <div style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:13px;"> <div style="font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px;"> <div dir="ltr"> <hr size="1"> <font face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> "<a rel="nofollow" target="_blank" href="mailto:bbutler@...">bbutler@...</a> [vantage]" <<a rel="nofollow" target="_blank" href="mailto:vantage@yahoogroups.com">vantage@yahoogroups.com</a>><br> <b><span style="font-weight:bold;">To:</span></b> <a rel="nofollow" target="_blank" href="mailto:vantage@yahoogroups.com">vantage@yahoogroups.com</a> <br> <b><span style="font-weight:bold;">Sent:</span></b> Thursday, September 10, 2015 7:22 AM<br> <b><span style="font-weight:bold;">Subject:</span></b> [Vantage] E10.0.704: BPM C# Runtime error with query statement<br> </font> </div><span class="ygrps-yiv-1750003375"> <div><br><div>
From what I can see through various stackoverflow & MSDN post, LINQ doesn't like the section:
where ttOrderHed_Row["OrderType_c"] == "Machine"Âfrom the following code snippet:var ttOrderHed_xRow =   (from ttOrderHed_Row in ttOrderHed    where ttOrderHed_Row["OrderType_c"] == "Machine"    select ttOrderHed_Row).FirstOrDefault();From what I understand LINQ converts to SQL and it is during this conversion that the program bombs out which explains while it compiles and saves, but fails when the BPM is called.ÂI am struggling to understand how I can get this in a format that C# can deal with.Â
</div>
<div style="color:#fff;min-height:0;"></div>
Just make it look like this, and you won't have that issue as long as OrderType_C is a string.
var ttOrderHed_xRow =
(from ttOrderHed_Row in ttOrderHed
where ttOrderHed_Row.OrderType_c == "Machine"
select ttOrderHed_Row).FirstOrDefault();
Jose C Gomez
T: 904.469.1524 mobile
Quis custodiet ipsos custodes?
On Fri, Sep 11, 2015 at 9:11 AM, amathis@... [vantage] <vantage@yahoogroups.com> wrote:Â<div> <p></p><p>Just make it look like this, and you won't have that issue as long as OrderType_C is a string.</p><span class="ygrps-yiv-226945715"><p><br></p><div><p style="background:white;"><span style="color:black;">var ttOrderHed_xRow =Â </span></p></div><div><p style="background:white;"><span style="color:black;">Â Â Â (from ttOrderHed_Row in ttOrderHed</span></p></div></span><div><p style="background:white;"><span style="color:black;">Â Â Â Â where ttOrderHed_Row.OrderType_c == "Machine"Â </span></p></div><div><p style="background:white;"><span style="color:black;">Â Â Â Â select ttOrderHed_Row).FirstOrDefault();</span><br></p></div><p></p> </div> <div style="color:#fff;min-height:0;"></div>
-------- Original message --------
From: "amathis@... [vantage]" <vantage@yahoogroups.com>
Date: 09/11/2015 8:13 AM (GMT-06:00)
To: vantage@yahoogroups.com
Subject: [Vantage] Re: E10.0.704: BPM C# Runtime error with query statement
Just make it look like this, and you won't have that issue as long as OrderType_C is a string.
var ttOrderHed_xRow =
(from ttOrderHed_Row in ttOrderHed
where ttOrderHed_Row.OrderType_c == "Machine"
select ttOrderHed_Row).FirstOrDefault();
Jose C Gomez
T: 904.469.1524 mobile
Quis custodiet ipsos custodes?
On Fri, Sep 11, 2015 at 9:16 AM, 'Butler, Bruce' bbutler@... [vantage] <vantage@yahoogroups.com> wrote:Â<div> <p><u></u>
That was my first iteration,and tried again last night. Â I assume this doesn't work because it is an extended field.
Thanks for the suggestion.Â
Sent from my Verizon Wireless 4G LTE smartphone
-------- Original message --------
From: "amathis@... [vantage]" <vantage@yahoogroups.com>
Date: 09/11/2015 8:13 AM (GMT-06:00)
To: vantage@yahoogroups.com
Subject: [Vantage] Re: E10.0.704: BPM C# Runtime error with query statement
ÂJust make it look like this, and you won't have that issue as long as OrderType_C is a string.
var ttOrderHed_xRow =Â
   (from ttOrderHed_Row in ttOrderHed
    where ttOrderHed_Row.OrderType_c == "Machine"Â
    select ttOrderHed_Row).FirstOrDefault();
</div> <div style="color:#fff;min-height:0;"></div>