Re: [SQL] bug with if ... then ... clause in views

2006-01-18 Thread Daryl Richter
On Jan 18, 2006, at 4:18 AM, Emil Rachovsky wrote: While trying to create some views I stumbled on some problem with using the if-then clause. Here is a simple example : CREATE OR REPLACE VIEW public.SomeView as select d.id, if (true) then d.DocNumber endif from public.Z_Documents as d; I

Re: [SQL] bug with if ... then ... clause in views

2006-01-18 Thread Michael Glaesemann
On Jan 18, 2006, at 18:18 , Emil Rachovsky wrote: CREATE OR REPLACE VIEW public.SomeView as select d.id, if (true) then d.DocNumber endif from public.Z_Documents as d; I get the following error : syntax error at or near "then" at character 72 Well, one problem is that IF ... ENDIF is the

[SQL] bug with if ... then ... clause in views

2006-01-18 Thread Emil Rachovsky
While trying to create some views I stumbled on some problem with using the if-then clause. Here is a simple example : CREATE OR REPLACE VIEW public.SomeView as select d.id, if (true) then d.DocNumber endif from public.Z_Documents as d; I get the following error : syntax error at or near "t