Using cursor.callproc with zxJDBC
Carsten Haese
carsten at uniqsys.com
Fri Aug 3 13:08:31 EDT 2007
On Fri, 2007-08-03 at 17:31 +0100, Vaughan V Ashe wrote:
> Hi
>
> We would like to use the store proc. We are using a postgreql
> database. what we have working so far is:
>
> params = [4,4,2]
>
> curs.callproc("update_job_status",params)
>
> db.commit()
>
> #print db
>
> #print curs.description
>
> result = curs.fetchall()
>
> if result == 1:
>
> print "good one"
>
> else:
>
> print "shite"
>
>
>
> we are using the beta version of jython. Would be very happy to get a
> response from you
You haven't asked a question, and you're not describing what your
problem is.
I'm going to guess what your problem is: You're always getting the
result "shite" regardless of whether the procedure worked or not.
curs.fetchall() returns a list, which is never going to be equal to 1.
If this doesn't help you, please describe what exactly your problem is.
--
Carsten Haese
http://informixdb.sourceforge.net
More information about the Python-list
mailing list