Skip site navigation (1) Skip section navigation (2)

ODBC, ADO, Return Value from SP problem

From: Pavel Stehule <stehule(at)kix(dot)fsv(dot)cvut(dot)cz>
To: pgsql-general(at)postgresql(dot)org
Subject: ODBC, ADO, Return Value from SP problem
Date: 2004-05-31 13:09:55
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-general

	I need use ADODB client via ODBC. I can call stored proc
without problems. I am sure so proc is called (I am loging params)
but retern value is always null.

dim cn as new ADODB.Connection()
Dim cmd As New ADODB.Command
Set cmd.ActiveConnection = cn
cmd.CommandText = "testcallsp"
cmd.CommandType = adCmdStoredProc
cmd.Parameters(1).Value = 22
MsgBox cmd.Parameters(0).Value 'only null :-((

Stored Proc is simply 

CREATE OR REPLACE FUNCTION testcallsp(integer) RETURNS integer AS '
  RAISE LOG ''% '', $1;
  RETURN coalesce($1,10) + 1;
END; ' LANGUAGE plpgsql;

What is wrong please? 

Thank You very much
Pavel Stehule


pgsql-general by date

Next:From: Alvaro HerreraDate: 2004-05-31 13:13:36
Subject: Re: Dump 7.1.3->7.4.2
Previous:From: Ben-Nes MichaelDate: 2004-05-31 10:49:51
Subject: pg_dump and errors

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group