Oracle sql "case when"

Feature requests and their debate

Oracle sql "case when"

Postby FoxXav » Mon Mar 14, 2016 8:45 am

Hi,

It seems that the sql syntax for Oracle case when is not implemented as I got error with query using this syntax (and not under sqldeveloper).
Is it possible to add it to the great dbeaver ?

See you
FoxXav
 
Posts: 4
Joined: Thu Jan 29, 2015 3:11 pm

Re: Oracle sql "case when"

Postby Serge » Mon Mar 14, 2016 5:32 pm

Similar problem was fixed a couple of version ago.
Do you use recent (3.6.2) version?
Can you post an example of problem query?
Serge
 
Posts: 1526
Joined: Sat Feb 26, 2011 8:24 pm
Location: SPb

Re: Oracle sql "case when"

Postby FoxXav » Thu Mar 24, 2016 9:53 am

Hi,

yes I use the latest version of dbeaver here is a request just to show the problem (no meaning in this) that didn't work in dbeaver but work in sqldeveloper :

select SUM(case when (1=0) then 1 else 0 end), SUM(case when (1=1) then 1 else 0 end)
from dual;

It seems that it's due to the use of the "case when" inside an aggregation function.
Hope it will help

See you
FoxXav
 
Posts: 4
Joined: Thu Jan 29, 2015 3:11 pm

Re: Oracle sql "case when"

Postby Serge » Thu Mar 24, 2016 10:39 am

Yep, it is a bug in DBeaver (it incorrectly determines query end). Will fix it in the next version (3.6.3).
Thanks for report.

As a workaround you can select your query and execute it with Ctrl+enter.
Serge
 
Posts: 1526
Joined: Sat Feb 26, 2011 8:24 pm
Location: SPb

Re: Oracle sql "case when"

Postby FoxXav » Thu Mar 31, 2016 7:41 am

Just try the 3.6.3 seems to work so far :-)

Great.

thank you.
FoxXav
 
Posts: 4
Joined: Thu Jan 29, 2015 3:11 pm


Return to Feature Requests



Who is online

Users browsing this forum: No registered users and 15 guests