Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #68307

Re: DB API question - where is a stored procedure's return value?

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news.stack.nl!newsfeed.xs4all.nl!newsfeed3a.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <ian.g.kelly@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.043
X-Spam-Evidence '*H*': 0.91; '*S*': 0.00; 'subject:question': 0.10; '5:00': 0.16; 'be:': 0.16; 'subject:API': 0.16; 'subject:where': 0.16; 'wrote:': 0.18; 'wed,': 0.18; 'properly': 0.19; 'sorry,': 0.24; 'header:In-Reply-To:1': 0.27; 'message-id:@mail.gmail.com': 0.30; 'received:google.com': 0.35; 'subject:?': 0.36; 'should': 0.36; 'to:addr:python-list': 0.38; 'pm,': 0.38; '12,': 0.39; 'to:addr:python.org': 0.39; 'skip:p 20': 0.39; 'ian': 0.60; 'mar': 0.68
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=JeeS99dNh96dLp3c//qII2tBxsFfsDNeDSCqhIz9AUA=; b=qBgaQSlr/RNo+nuaxOGoecoGYlJna3ZXvrsTPXJp2uS17WQGhiTBriGfqtmk+8feAP KtOOOsokUFS2wtdF2LcaC1Qmdc4l9MCxA0BOC7sONSyFWgZyqmx/imSVBGWy9cDdQvCs cLOSAItqXaRJNA/ETWAHKqTdPyDChyF9333DZST/ZL6TUS99uPGxZmoV4BwR+zzVRT5C jN6ocIvGWqzJ5sCjUabRF+mh4rNcjelfu8KzSrpfY22eEnxhNyI8H7pdd6otpe957oXB IBQqZ75jrjx14wM7c/+Exj1qFSwWl0BJa8lBOa+nHoPViB32JQnwwZywbbfOCxwFI+oQ jXww==
X-Received by 10.68.110.165 with SMTP id ib5mr145647pbb.61.1394665651169; Wed, 12 Mar 2014 16:07:31 -0700 (PDT)
MIME-Version 1.0
In-Reply-To <CALwzidm0GJ37JTjUUGPPgEXnZoh0ck08B7i2H4SZXXD1VyDcbA@mail.gmail.com>
References <CANc-5Uz98mTCjUuk_yOHqWeZRwp6JnTCagTQ=bzobhtWAceKxg@mail.gmail.com> <CALwzidm0GJ37JTjUUGPPgEXnZoh0ck08B7i2H4SZXXD1VyDcbA@mail.gmail.com>
From Ian Kelly <ian.g.kelly@gmail.com>
Date Wed, 12 Mar 2014 17:06:50 -0600
Subject Re: DB API question - where is a stored procedure's return value?
To Python <python-list@python.org>
Content-Type text/plain; charset=ISO-8859-1
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.8112.1394665660.18130.python-list@python.org> (permalink)
Lines 10
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1394665660 news.xs4all.nl 2904 [2001:888:2000:d::a6]:50814
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:68307

Show key headers only | View raw


On Wed, Mar 12, 2014 at 5:00 PM, Ian Kelly <ian.g.kelly@gmail.com> wrote:
>     result = cursor.var(cx_Oracle.NUMBER)
>     cursor.execute(":1 := test_proc()", [result])
>     print(result.getvalue())

Sorry, that should properly be:

    result = cursor.var(cx_Oracle.NUMBER)
    cursor.execute("BEGIN :1 := test_proc(); END;", [result])
    print(result.getvalue())

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: DB API question - where is a stored procedure's return value? Ian Kelly <ian.g.kelly@gmail.com> - 2014-03-12 17:06 -0600

csiph-web