From:             aspen dot olmsted at alliance dot biz
Operating system: Windows XP SP2
PHP version:      5.2.0
PHP Bug Type:     PDO related
Bug description:  Sending more then one parameter to SP will not return output 
parameters

Description:
------------
I am trying to pass output parameters to MSSQL through PDO using the odbc
driver.

If there is just one parameter it works.  If there is more than one it
will not.

There is a sample to send an inout parameter to SQL on the pdo
documentation page I used as a starting place

Reproduce code:
---------------
SQL:

ALTER PROCEDURE spReturn_Int @err int OUTPUT, @err2 varchar(255)
AS
SET @err = 11

  $sth = $dbh->prepare("EXECUTE spReturn_Int ?");
  $invalue = 'Dog';
  $sth->bindParam(1, $return_value,
PDO::PARAM_INT|PDO::PARAM_INPUT_OUTPUT);
  $sth->bindParam(2, $invalue, PDO::PARAM_STR);
  $sth->execute();
  print "procedure returned $return_value\n";


Expected result:
----------------
It should print "procedure returned 11"

Actual result:
--------------
It prints "procedure returned 

-- 
Edit bug report at http://bugs.php.net/?id=39707&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=39707&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=39707&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=39707&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=39707&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=39707&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=39707&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=39707&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=39707&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=39707&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=39707&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=39707&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=39707&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=39707&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=39707&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=39707&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=39707&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=39707&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=39707&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=39707&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=39707&r=mysqlcfg

Reply via email to