Skip to main content



      Home
Home » Archived » EGL Development Tools » Cannot use GET with FROM clause within FOREACH
Cannot use GET with FROM clause within FOREACH [message #810818] Thu, 01 March 2012 10:40 Go to next message
Eclipse UserFriend
EGL Development Tools
Version: 0.8.0.v201202280901-1Co-FjuJ6QMNSP3ynscd8h8C
DedicatedService
Eclipse 3.7.1
Generation Language: Java, JavaScript

Error:
IWN.VAL.6510.e 36/28
The FOREACH SQL I/O statement does not allow the FROM option to be specified more than once.

...
ds SQLDataSource? {@Resource{uri="binding:SomeValidBinding"}};
...
 
function ...
 
  rs SQLResultSet?;
  open rs from ds using(someParameter) with #sql{
    select * from someTable where someField = ?
  };
  someRecord1 SOMERECORD;
  forEach (someRecord1 from rs)
    someOtherRecord1 SOMEOTHERRECORD { id=someRecord1.ID };
    get someOtherRecord1 from ds; <-- ERROR occurs here
  end

end


Is this illegal syntax?
Re: Cannot use GET with FROM clause within FOREACH [message #810837 is a reply to message #810818] Thu, 01 March 2012 10:57 Go to previous messageGo to next message
Eclipse UserFriend
Hi Daniel,

This is a bug in validation. Please submit a bug report at "https: //bugs.eclipse .org/bugs/enter_bug.cgi?product=EDT" (remove the spaces, this forum isn't allowing me to post hyperlinks).

For now you can work around this by putting the code in another function and invoking the function inside the forEach block.

-Justin
Re: Cannot use GET with FROM clause within FOREACH [message #810921 is a reply to message #810837] Thu, 01 March 2012 12:32 Go to previous message
Eclipse UserFriend
Will submit the bug. Thanks for the quick reply, Justin!
Previous Topic:Forward & onprerender function in EDT
Next Topic:Dojo Widget Error in Using Handler
Goto Forum:
  


Current Time: Wed May 14 01:27:18 EDT 2025

Powered by FUDForum. Page generated in 0.03055 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top