Hi All,

I am using the racket 'db' module to interact with my postgresql database.
I think there is some mismatch in the documentation towards the end of
section 1.1. Here is my sample repl session.

> (define get-less-than-pst
    (prepare pgc "select n from the_numbers where n < $1"))

> (query-list pgc get-less-than-pst 1)
'(0)
*> (query-list pgc (bind-prepared-statement get-less-than-pst 2))*
*. . bind-prepared-statement: contract violation, expected: list?, given: 2*
*  contract from: <collects>/db/base.rkt, blaming: anonymous-module*
*  contract: *
*    (-> prepared-statement? list? any)*
*  at: <collects>/db/base.rkt:125.2*
*> *
*
*
After checking the documentation for the 'bind-prepared-statement' it
expects a variable and a list as it parameter types. Is this correct or am
I missing something?

Bikal
____________________
  Racket Users list:
  http://lists.racket-lang.org/users

Reply via email to