Subject A view on a SELECT with stored procedure
Author kimon_the_athenian2
Hi, new puzzle again :)

This select:

> select t.id,
> sp.some_calculation,
> sp.related_calculation,
> sp.yet_another_calculation
> from sometable t LEFT join somesp (t.id)sp on (0=0)

works fine, but when I try to create a view on this query:

> create view someview
> (id, x, y, z)
> as
> select t.id,
> sp.some_calculation,
> sp.related_calculation,
> sp.yet_another_calculation
> from sometable t LEFT join somesp (t.id)sp on (0=0)

then I get dynamic sql error complaining about first "(" on the last
line.


I read from IB documentation, that view on "union select" can be
created only with embedded SQL, not with DSQL. Can this be the case
with this kind of view also?
Is creating a C program the only way for executing embedded SQL?


Aivar