I was wondering if it wouldn't be possible and make sense to have openacs generate a tcl proc automatically for each available pl/sql procedure, so that for example for the pl/sql proc bookmark.new a tcl proc db_plsql::bookmark::new is created, with all it's allowed parameters as named parameters.
So that instead of writing db_exec_plsql and tediously having to translate it for the two databases, you could just call:
db_plsql::bookmark::new -owner_id $owner_id -parent_id $parent_id -creation_user $user_id ...
Possibly even with optional pl/sql parameters resulting in an optional tcl parameter and required pl/sql resulting in required tcl parameters, so that the error messages make sense when calling it wrongly.
I don't know exactly how/if that would be possible, but I guess both databases provide us with some kind of information about the available pl/sql procedures, no?
Comments?