Fine, I see my mistake -- I won't be able to do all the nice things through proper OpenACS toolset, but I do get access to raw AOLServer calls, etc. It now is just a question how to marry it with templating (if at all, may as well just right good-ol' Tcl pages...)
Re-written as follows:
set dbpool "boflex"
set db [ns_db gethandle $dbpool]
set query "select count(*) cntr from dual"
set row [ns_db 0or1row $db $query]
set cnt [ns_set get $row cntr]
ns_return 200 text/html "<h1>$cnt</h1>"
...works correctly
Thanks again,