Page 1 of 1

expression evaluation error in SQL select with case-statemnt

Posted: Mon 18 Jan 2010 09:49
by mischerr
Hi.

I'm getting a "Dynamic SQL Error expression evaluation not supported." when running the following SQL statement.

Code: Select all

select case when max(nummer) is null then 10000 else max(nummer)+1 end from kunden
While this was running fine using the old BDE I can only run a workaround changing the statement to:

Code: Select all

select case when max(nummer) is null then 9999 else max(nummer) end from kunden
... and then increment the result by code.

Any idea on this issue?

Michael

Using IBDAC 3.1, FB2.1

Posted: Tue 19 Jan 2010 12:14
by Plash
Please provide us a script for creating the table.