About EasyMorph Tutorials & Examples Web-help

Module Error in Server but not Desktop

Hi,

Since the release of version 4 and the ability to use modules, I have been integrating “iteration jobs” into modules.

So far there haven’t been any issues., however a couple of recent modules are failing when run via EM Server, however they complete fine when using the desktop version.

The job typically creates a range of dates from today to +18 months, and iterates through each month individually passing date parameters as “StartDate_date” and “EndDate_date”, which simply imports data from a SQL database between those dates (Import from Database Action), deletes any existing data in an external table within that date range (Delete Matching Database Rows Action), and then saves it out to another database table (Database Command and Export to Database Actions).

Everything runs fine in the desktop version, however when the project is published to EM server and run, I receive the following errors:

000025 ERROR action “Import from database”, module “Module1”, table “Table1”: Column type (date with time) is not compatible with value type (unknown) in condition is between {StartDate_date} and {EndDate_date}.
000026 ERROR action “Iterate”, module “Main”, table “Table1”: Iteration of module “Module1” failed on iteration #1.
000027 ERROR action “Delete database rows”, module “Module2”, table “Table2”: Column type (date) is not compatible with value type (unknown) in condition is between {StartDate_date} and {EndDate_date}.
000028 ERROR action “Iterate”, module “Main”, table “Table2”: Iteration of module “Module2” failed on iteration #1.

In “Module1”, the Import query is a plain database table using the in-built visual mode (i.e not a Custom SQL) and a between condition. “Module2” Import query is a Custom SQL and the WHERE clause pulling the parameters.

Desktop version is 4.0.1.4; server version is 4.1.0.0

UPDATE: If I change the query to Custom SQL mode for “Module1” and keep the generated query text as-is, it no longer fails at this step, but it next fails at the same point as “Module2” in the “Delete Database Rows” action. The queries in both of those actions also use the built-in visual mode with a between condition. I cannot change these to Custom SQL mode as there is an error stating that you cant use Custom SQL for that action.

Any ideas?

@andrew.rybka, can you please take a look here.

Hi @jaws2k,

This looks like a bug from our side. Thank you for reporting it. We’ll have to investigate it further.

As a workaround you can continue to use subprojects instead of modules. It seems that subprojects are not affected by this bug.

Hi Aaron,

we’ve published an updated version on our download page with the bug fixed. Can you please try it.

Unfortunately, for the server version, I am unable to verify if the fix works given that upgrades to the server version are more “scheduled” events requiring outages.

As a side note, I upgraded my desktop version to 4.1.0.6 (previous 4.0.1.4), and I received the same error in the Desktop version (in the OP it worked fine).

I upgraded to 4.1.0.9 after your reply, and the error does not occur in desktop.

Thanks, Aaron.

To learn more about EasyMorph visit easymorph.com.