|
From: Adriano d. S. F. <adr...@gm...> - 2009-07-31 01:13:28
|
Leyne, Sean wrote: > Adriano, > > >> Instead of try some other way to fix this problem and CORE-2538 at the >> same time, I'd like to propose a new thing. >> >> Currently, we explicitly make it impossible to do things as: >> var = (select ... from ...); >> if ((select ... from ...) = 1) then >> >> Apparently, that works ok. Won't it be much better to revert CORE-2538 >> and eliminate this prohibition? >> > > I'm not sure if I understand what exactly you are proposing, I find your post a little confusing. > > Please elaborate. Now: SQL> execute block CON> as CON> declare n integer; CON> begin CON> if ((select 1 from rdb$database) = 0) then CON> n = 1; CON> end! Statement failed, SQLSTATE = 42000 Dynamic SQL Error -SQL error code = -206 -Subselect illegal in this context I propose this code should compile and work. Why not? At the same time, the regression is fixed without rollback CORE-2538 fix or found another "clever" solution. Adriano |