Hi folks,

I've just checked in a patch to the trunk of the release/3/postgresql
egg, providing support for query parameters. If anyone else is using
this egg, I'd appreciate your checking out this version and testing
it.

In all of the querying procedures, the new interface lets you replace
the query-string argument with a list, (query-string . args). Given a
list, the new code uses the PQsendQueryParams call, so escaping of
parameters is handled automatically.

Examples:

;; old interface (still works)
(pg:query-tuples "select foo, bar from baz" the-conn)

;; new interface
(pg:query-tuples
 (list "select foo, bar from baz where foo > $1 and baz < $2"
       foo-low baz-high)
 the-conn)

Felix, I believe that Johannes is no longer maintaining the postgresql
egg. I would be happy to maintain it if no one objects.

Thanks,
Graham


_______________________________________________
Chicken-users mailing list
Chicken-users@nongnu.org
http://lists.nongnu.org/mailman/listinfo/chicken-users

Reply via email to