Without seeing an error message, I have no ideas. Are you sure that
lighttpd error logging is enabled? If you still can't get the error from
lighttpd, maybe add a with-handlers around the failing db call and write
it to your own log file.
Ryan
On 03/27/2013 02:27 PM, prad wrote:
i have a working cgi script in racket which accesses a sqlite3 db:
====
#lang racket
(require net/cgi)
(require db/base db/sqlite3)
(define cn (sqlite3-connect #:database "tmp.db"))
; (query-rows cn "select nm from tbl")
(query-exec cn "insert into tbl (nm) values ('hello')")
====
if i do the:
(query-rows cn "select nm from tbl")
it works fine.
if i do the:
(query-exec cn "insert into tbl (nm) values ('hello')")
i get 500 internal server error
both statements work fine from the console.
i've tried changing permissions to 777 on the tmp.db but doing so
doesn't make any difference.
i'm using lighttpd so i thought the error might show up in
/var/log/lighttpd/error.log
but it doesn't.
nor does anything show up in
/var/log/messages
1. how can i see error messages when using racket as cgi with lighttpd (on
debian).
2. if #1 isn't possible for some reason, any ideas on why i can read,
but not write to the sqlite db?
____________________
Racket Users list:
http://lists.racket-lang.org/users