ID:               33184
 Updated by:       [EMAIL PROTECTED]
 Reported By:      brad_allgood at csgsystems dot com
-Status:           Open
+Status:           Feedback
 Bug Type:         ODBC related
 Operating System: Windows XP
 PHP Version:      5.0.4
 New Comment:

Is it working any better..?



Previous Comments:
------------------------------------------------------------------------

[2005-06-01 15:56:05] brad_allgood at csgsystems dot com

Thanks for the clarification.  I'll try to upgrade my client to V8.2
and try and see just how "wonky" things get. (smile).

------------------------------------------------------------------------

[2005-06-01 15:49:16] [EMAIL PROTECTED]

Brad: sorry, yes, the ibm_db2 extension requires a minimum of DB2 V8.2
(V8.1 FP7). And V8 -> V7 connections might be a little wonky.

------------------------------------------------------------------------

[2005-05-31 20:15:41] brad_allgood at csgsystems dot com

I can not get the PECL extension to work.  When I load it via the
php.ini setting:

"extension=php_ibm_db2.dll"

I get the following errors when I try invoke the script via the command
line

 php.exe - Entry Point Not Found
 The procedure entry point [EMAIL PROTECTED] could not be located in the
dynamic link library DB2CLI.dll

 Warning:
 PHP Startup: Unable to load dynamic library
'c:\php\ext\php_ibm_db2.dll' - The specified procedure could not be
found.

On the machine I am running the script from (client) the dblevel
command outputs:

DB21085I  Instance "DB2" uses DB2 code release "SQL07010" with level
identifier

"02020105" and informational tokens "DB2 v7.1.0.1", "n000727" and
"WR21198".

On the machine that has the database I am querying the db2level command
outputs:

DB21085I  Instance "db2inst1" uses DB2 code release "SQL07020" with
level 
identifier "03010105" and informational tokens "DB2 v7.1.0.40",
"s010415" and 
"U475375".


So given all this am I to understand that the PECL db2 component is not
a viable option for me unless I upgrade to DB2 V8.1?

I am assuming that is the issue with the ibm_db2_php.dll starting up
due to dependencies in db2_cli.dll ... unless I've got something goofy
in my pathing to get to the db2_cli.dll.

The "echo %PATH%" command I am running the php command from is 


echo %PATH%

C:\Perl\bin\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program
Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\ActiveState
Komodo 3.1
\;c:\php;C:\Program Files\SQLLIB\BIN;C:\Program
Files\SQLLIB\HELP;c:\php\ext;c:\
php\includes;c:\php\includes\jpgraph;c:\php\includes\jpgraph\src

The db2cli.dll is located in c:\Program Files\SQLLIB\BIN which is in my
path.

Back to the orignal submission:

It looked like in 16221 someone had a track on this in the 4.X branch
of code.  Did this not pan out or has that cause been ruled out as part
of the original odbc related bug submission I created?

------------------------------------------------------------------------

[2005-05-31 00:01:09] [EMAIL PROTECTED]

Brad:

1) Can you reproduce the error with the PECL ibm_db2 extension? You can
grab the php_ibm_db2.dll from http://snaps.php.net/, change odbc_* to
db2_* in your function calls (with the exception of odbc_connect() -- I
think you'll need to add USER=user;PASSWORD=password; to your connection
string and pass nulls for the second and third parameter), and
everything _should_ work. Note that this requires a minimum of DB2
V8.2.

2) What levels of DB2 are you running on your Windows box and AIX
server?

------------------------------------------------------------------------

[2005-05-30 20:24:07] brad_allgood at csgsystems dot com

Okay ... I'm inlcuding a script written and tested on my machine to
reproduce the error:

//################## Script Start ########################
<?php


     $b_date = '05/25/2005';
     $b_time = '09:00:00';
     $m_mach_sn = "075-21752";

     $connect_string = "Driver={IBM DB2 ODBC
Driver};HOSTNAME=host.domain.com;DATABASE=TEST;PROTOCOL=TCPIP;PORT=50000;";
     
     $conn = odbc_connect($connect_string, 'user', 'password');

     $counter=0;
     while ($counter <5000)
     {
         $vpcfg_qry = "select distinct m_mach_sn, m_cluster_n,
m_card_num, m_lss_la, m_array_id, m_loop_id, m_grp_num, m_disk_num
                       from db2inst1.vpcfg
                       where m_mach_sn = '$m_mach_sn'
                       order by m_mach_sn, m_card_num, m_cluster_n,
m_loop_id, m_grp_num
                      ";
         // Get Result
         $vpcfg_result = odbc_exec($conn,$vpcfg_qry);
     
         //print
"m_mach_sn|m_cluster_n|m_card_num|m_lss_la|m_array_id|m_loop_id|m_grp_num|m_disk_num|m_dbl_wide<br>\n";
         // Get Data From Result
         $vpcfg_row_count = 0;
         while ($vpcfg_row[] = odbc_fetch_array($vpcfg_result))
         {   
             $m_mach_sn = $vpcfg_row[$vpcfg_row_count]["M_MACH_SN"];
             $m_cluster_n =
$vpcfg_row[$vpcfg_row_count]["M_CLUSTER_N"];
             $m_card_num = $vpcfg_row[$vpcfg_row_count]["M_CARD_NUM"];
             $m_lss_la = $vpcfg_row[$vpcfg_row_count]["M_LSS_LA"];
             $m_array_id = $vpcfg_row[$vpcfg_row_count]["M_ARRAY_ID"];
             $m_loop_id = $vpcfg_row[$vpcfg_row_count]["M_LOOP_ID"];
             $m_grp_num = $vpcfg_row[$vpcfg_row_count]["M_GRP_NUM"];
             $m_disk_num = $vpcfg_row[$vpcfg_row_count]["M_DISK_NUM"];
         }
         print "Counter = $counter\n";
         $counter = $counter + 1;
     }    
     odbc_close($conn)
?>
//################## Script End   ########################

------------------------------------------------------------------------

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/33184

-- 
Edit this bug report at http://bugs.php.net/?id=33184&edit=1

Reply via email to