question

David Besson avatar image
0 Likes"
David Besson asked Jason Lightfoot edited

SQL table query exception when included in a user command (only 19.2)

The behaviour of my table query depends from where I execute it:

  • through the script console -> it behaves as expected
  • through a user command -> it throws an exception

Did I do something wrong? Please notice it worked with the previous version 19.1.2.
Could it be related also to this post?

Thanks!

sql-exception-query-in-command.fsm

FlexSim 19.2.0
sql queries
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

·
Phil BoBo avatar image
0 Likes"
Phil BoBo answered Jason Lightfoot edited

It is related to this post: SQL Query Error - Flexsim 19.2

The issue is not Script vs User Command. The issue is whether you have breakpoints in the code.

If you have breakpoints in a FlexScript function or you have the debug() command anywhere within a FlexScript function, then the FlexScript compiler does not compile the entire function at once. Instead, it compiles and executes one line at a time so that you can debug it.

Something in our changes to the table query commands in 19.2.0 broke this one-line-at-a-time execution of table queries. We've added a case to the dev list to fix this.

5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.