Subject Re: [ib-support] Intriguing doubts or bugs ?!?!
Author Ivan Prenosil
> 1)
> I can submit this query (for example from a tool like IBAdmin) :
>
> SELECTssp.some_output_param, st.some_colum
> FROM some_stored_procedure ssp JOIN some_table st ON
> (ssp.some_output_param = st.some_colum)
>
> Why can't I create a VIEW from this ?

IB does not support stored procedures in views (i.e. in main FROM clause)


> 2)
> In Stored procedure I am using the code below to Set a MyNEWVAR value to a
> Generator :
> ...
> somevar = - 1 * Gen_Id( "SOME_GEN", 0 );
> somevar = Gen_Id( "SOME_GEN", somevar );
> somevar = Gen_Id( "SOME_GEN", MyNEWVAR );
> ....
>
> Is there any other way to do this ?

somevar = GEN_ID (SOME_GEN, MyNEWVAR - GEN_ID (SOME_GEN,0) )

What do you need it for ? You risk that you will get duplicate values
from generator if you set it to wrong value.

Ivan
http://www.volny.cz/iprenosil/interbase