[plt-scheme] schemeql
Anton van Straaten wrote:
>I did notice that using SrPersist directly, when functions like 'connect'
>are invoked, DrScheme returns the ladybug icon with a status message such as
>"SQL_SUCCESS_WITH_INFO occurred in connect". Because of this, I can't
>execute a script all at once, since it stops whenever it gets to such a
>statement. I assumed that SchemeQL does whatever it needs to to deal with
>this, though.
>
That, I have a solution for.
Simply call each command inside a
(with-handlers ([exn? (lambda (e) e)])
<command>)
To make it simpler you can
(define-macro try
(lambda commands
`(with-handlers ([exn? (lambda (e) e)])
. ,(append commands `(#f)))))
Then you can call each command as
(try <command>)
Katsmall the Wise
esiW eht llamstaK