VS eats my SP

Ruslan Zasukhin sunshine at public.kherson.ua
Sun Oct 7 01:00:08 CDT 2007


On 7/10/07 12:04 AM, "Barry G. Sumpter" <BarrySum at BigPond.Net.AU> wrote:

> This is how to reproduce the error
> 
> Execute this in a sql tab
> 
> 
> CREATE OR REPLACE PROCEDURE xxx( IN inValue long, Out outValue Long )
> BEGIN
>       IF inValue > 0 THEN
>            inValue = CEIL(inValue);
>       END IF
>  END
>  
>  
> 
> 
> Then
> Execute this in another sql tab
> 
> 
>  set @inValue = 1.59;
>  call xxx( @inValue, @outValue );
>  select @outValue;
> 
> the results are returned properly
> 
> in the 'number of records: 1'  result - click on the white space
> - and I get an error or VS freezes
> 
> I return to VS and stored procedures are not there.
> 
> Other times I create the stored procedure
>   - flush DB or restart VS or restart Winxp
>     - SP is still there
>        - then Execute the 2nd qry and same thing happens - error or freeze
>             - then return to VS and the SP is gone
> 
>  
> Hth

Ivan, please check this issue. Report into Mantis also.

> I'll have to drop my Valentina SP research for now
> as I need to move on to other more progressive assignments.

Btw, Barry,

1) in fact your procedure has mistake I think, must be as

CREATE OR REPLACE PROCEDURE xxx( IN inValue long, Out outValue Long )
BEGIN
       IF inValue > 0 THEN
            outValue = CEIL(inValue)
       ELSE
            outValue = inValue
       END IF
END


2) this PROCEDURE in fact is good candidate to be FUNCTION

CREATE OR REPLACE FUNCTION xxx( IN inValue long )
RETURNS LONG
BEGIN
       IF inValue > 0 THEN
            return CEIL(inValue)
       ELSE
            return inValue
       END IF
END


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list