Error -213

Started by Paul S., August 18, 2011, 09:54:30 PM

Previous topic - Next topic

Paul S.

When doing large searches I allow the user to press the "Cancel" button to interrupt the SQL.

This all works fine, but an error -213 always appears in the errorlog , is there any way to stop this happening.

Using later 2.32.x versions of frontend (Redhat) and backend (windows-xp)

Thanks

Paul

Sebastien F.

Hello Paul,

Can you provide a sample to reproduce?

With the following code I don't get any error trace in the log file:

Code (genero) Select
main
    define i int
    call startlog("mylog.txt")
    defer interrupt
    options sql interrupt on
    database test1
    create temp table tt1 ( k int, c char(10) )
    for i=1 to 1000
        insert into tt1 values ( 1, 'aaaa' )
    end for
    open form f1 from "int"
    display form f1
    menu "test"
       command "go"
          let int_flag = false
          whenever error continue
          select count(*) from tt1 a1, tt1 a2, tt1 a3, tt1 a4
          whenever error stop
          display "int_flag = ", int_flag
          display "sqlcode  = ", sqlca.sqlcode
       command "exit"
          exit program
    end menu
end main


Are you using WHENEVER ERROR CONTINUE?

Doc ref:
https://4js.com/online_documentation/fjs-fgl-manual-html/User/SqlProgramming.html#SQL_INTERRUPTION
https://4js.com/online_documentation/fjs-fgl-manual-html/User/Exceptions.html#TRACE

Seb

Paul S.

Thanks for the reply, I will tried and get a test together over the weekend.

Paul