php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #56730 wrong result set
Submitted: 2005-12-17 05:26 UTC Modified: 2006-03-27 10:34 UTC
From: hellower at nate dot com Assigned: kraman (profile)
Status: Closed Package: ibm_db2 (PECL)
PHP Version: 5.1.1 OS: AIX 5.3
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: hellower at nate dot com
New email:
PHP Version: OS:

 

 [2005-12-17 05:26 UTC] hellower at nate dot com
Description:
------------
DB2(AIX 5.3/ DB2UDB 8.2/ 64bit instance)
 |
 |<-----------A_PLATFORM) windwos advanced serve 2000/Apache2.0.55 (Win32) PHP 5.1.1/pecl idbm_db2 1.1.6
 |
 |<-----------B_PLATFORM) AIX 5.3/Apache 1.3.34 64bit compile/PHP 5.1.1 64bit compile/pecl idbm_db2 1.1.6


A_platform & B_platform are using identical DATABASE server.
and php source for test is same too.
but result sets at A_platform/B_platfrom are different.


sorry my poor english

Reproduce code:
---------------
http://my.icitiro.com/loracler/bug/bug.zip



Expected result:
----------------
[B_platform] right result set
success
success
-------------------------------------------------------------------------------------------------------------
0     cat              Pook                                   3.20
1     dog              Peaches                               12.30
2     horse            Smarty                               350.00
-------------------------------------------------------------------------------------------------------------
0     cat              Pook                                   3.20
1     dog              Peaches                               12.30
2     horse            Smarty                               350.00
-------------------------------------------------------------------------------------------------------------



Actual result:
--------------
[A_platform] worng result set

fail
success
-------------------------------------------------------------------------------------------------------------
0     cat              Pook                                   3.20
0     dog              Peaches                               12.30
0     horse            Smarty                               350.00
-------------------------------------------------------------------------------------------------------------
272280680 cat              Pook                                   3.20
272280680 dog              Peaches                               12.30
272280680 horse            Smarty                               350.00
-------------------------------------------------------------------------------------------------------------



Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-12-17 07:58 UTC] hellower at nate dot com
Sorry.
Platform was reversed.

Result set at A_platfrom(windows) are right.

Result set at B_platfrom(aix 5.3) are wrong. 
B_platform is buggy.
 [2005-12-18 00:27 UTC] denials at gmail dot com
Interesting; this appears to be a type mismatch issue that just happens to work on 32-bit.

I've applied a simple patch to CVS head to try to enforce stricter type matching, but will get my hands on a 64-bit machine to actually test it out in a few days.
 [2006-01-03 09:07 UTC] denials at gmail dot com
Hey, Krishna -- happy new year! Any chance you can reproduce and / or fix this?
 [2006-01-10 14:03 UTC] denials at gmail dot com
Hellower, can you try the ibm_db2 package from CVS HEAD and let us know if that fixes the problem for you?

It would be great if you could give the ibm_db2 unit tests a run as well (you'll need to create the SAMPLE database by issuing the db2sampl command).
 [2006-01-14 02:21 UTC] hellower at nate dot com
Still not solved.

i sent you mail(Please check your Gmail account)

sorry for my poor english.
 [2006-02-09 08:49 UTC] denials at gmail dot com
Slow but steady progress -- the crash on connect should be resolved with the latest code from CVS HEAD. We had longs instead of ints for the char string lengths in _php_db2_connect_helper().

If you get the chance, could you run the unit tests in the ibm_db2/tests/ subdirectory and post the results here? Assuming you are currently in the /ibm_db2/ directory, edit ibm_db2/tests/connection.inc to reflect your DB2 connection credentials and then run the following command:

pear run-tests tests/

Thanks!
 [2006-03-12 01:21 UTC] kfbombar at us dot ibm dot com
Are you still having an issue with the code from CVS HEAD?  Also, did you run the tests in ibm_db2/tests subdirectory as denials requested?  Please let us know so we can help you out.

Thanks for the info!
 [2006-03-19 07:05 UTC] hellowre at nate dot com
Sorry for late response.--;

Currently, the test machine is out of order(h/w problem)
so, tape device is not regnized at server.

So, I can't recover test machine using backup tape.
Please, wait until a test machine will be recovered.

sorry for my poor english.
 [2006-03-27 10:14 UTC] hellower at nate dot com
1) It works good!! nice!

success
success
-------------------------------------------------------------------------------------------------------------
0     cat              Pook                                   3.20
1     dog              Peaches                               12.30
2     horse            Smarty                               350.00
-------------------------------------------------------------------------------------------------------------
0     cat              Pook                                   3.20
1     dog              Peaches                               12.30
2     horse            Smarty                               350.00
-------------------------------------------------------------------------------------------------------------

2)
sslgm110:/usr/local/src/php-5.1.2/ext/ibm_db2# pear run-tests tests/
Running 124 tests
PASS IBM-DB2: connect to a database[tests/test_001.phpt]
PASS IBM-DB2: connect to a database (uncataloged connection)[tests/test_002.phpt]
PASS IBM-DB2: Count number of affected rows[tests/test_003.phpt]
PASS IBM-DB2: db2_connect() - wrong user/pwd[tests/test_004.phpt]
PASS IBM-DB2: db2_connect() - bad user / bad pwd[tests/test_005.phpt]
PASS IBM-DB2: db2_connect() - passing options[tests/test_006.phpt]
PASS IBM-DB2: db2_pconnect() - passing options[tests/test_007.phpt]
PASS IBM-DB2: db2_num_rows - update[tests/test_010.phpt]
PASS IBM-DB2: db2_num_rows - delete[tests/test_011.phpt]
PASS IBM-DB2: db2_num_rows - select - scrollable cursor[tests/test_012.phpt]
PASS IBM-DB2: db2_num_rows - select - scrollable CURSOR[tests/test_013.phpt]
PASS IBM-DB2: scrollable cursor; retrieve negative row[tests/test_014.phpt]
PASS IBM-DB2: db2_num_rows - insert, delete[tests/test_015.phpt]
PASS IBM-DB2: db2_num_rows - insert, delete[tests/test_016.phpt]
PASS IBM-DB2: db2_rollback() - delete[tests/test_020.phpt]
PASS IBM-DB2: db2_commit() - delete[tests/test_021.phpt]
PASS IBM-DB2: db2_rollback() - insert[tests/test_022.phpt]
PASS IBM-DB2: db2_result[tests/test_030.phpt]
PASS IBM-DB2: db2_result (index by position)[tests/test_031.phpt]
PASS IBM-DB2: db2_result (index by name)[tests/test_032.phpt]
PASS IBM-DB2: db2_result (out of sequence column requests)[tests/test_033.phpt]
PASS IBM-DB2: db2_fetch_row()[tests/test_034.phpt]
PASS IBM-DB2: db2_fetch_row() - several rows[tests/test_035.phpt]
PASS IBM-DB2: db2_fetch_row() - several rows[tests/test_036.phpt]
PASS IBM-DB2: db2_fetch_row() (index by position) - 1[tests/test_037.phpt]
PASS IBM-DB2: db2_fetch_row() (index by position) - 2 - nested[tests/test_038.phpt]
PASS IBM-DB2: db2_fetch_row\(\) (index by position) - 3 - nested[tests/test_039.phpt]
PASS IBM-DB2: db2_result -- request a column that does not exist[tests/test_03a.phpt]
PASS IBM-DB2: db2_fetch_array one row[tests/test_040.phpt]
PASS IBM-DB2: db2_fetch_array several rows[tests/test_041.phpt]
PASS IBM-DB2: db2_fetch_array() - several rows 1[tests/test_042.phpt]
PASS IBM-DB2: db2_fetch_array() - several rows 2[tests/test_043.phpt]
PASS IBM-DB2: db2_fetch_array() - several rows 3[tests/test_044.phpt]
PASS IBM-DB2: db2_fetch_array() - one row binary data[tests/test_045.phpt]
PASS IBM-DB2: db2_fetch_array() - several rows 4[tests/test_046.phpt]
PASS IBM-DB2: db2_fetch_array() - several rows 5[tests/test_047.phpt]
PASS IBM-DB2: db2_fetch_array() - fetch one row of binary data[tests/test_048.phpt]
PASS IBM-DB2: db2_bind_param: INSERT statement - NULL parameter[tests/test_049.phpt]
PASS IBM-DB2: get autocommit value[tests/test_050.phpt]
PASS IBM-DB2: set autocommit value in connection string[tests/test_051.phpt]
PASS IBM-DB2: set autocommit with db2_autocommit[tests/test_052.phpt]
PASS IBM-DB2: db2_tables() - 1[tests/test_060.phpt]
PASS IBM-DB2: db2_tables() - 2[tests/test_061.phpt]
PASS IBM-DB2: db2_tables() - 3[tests/test_062.phpt]
PASS IBM-DB2: db2_tables() - 4[tests/test_063.phpt]
PASS IBM-DB2: db2_tables() - 5[tests/test_064.phpt]
PASS IBM-DB2: db2_tables() - Filter by table name[tests/test_065.phpt]
PASS IBM-DB2: db2_tables() - Play with table objects[tests/test_066.phpt]
PASS IBM-DB2: db2_close()[tests/test_070.phpt]
PASS IBM-DB2: db2_close() - success[tests/test_071.phpt]
PASS IBM-DB2: db2_conn_error() - wrong database alias[tests/test_080.phpt]
PASS IBM-DB2: db2_conn_error() - wrong username[tests/test_081.phpt]
PASS IBM-DB2: db2_conn_error() - wrong password[tests/test_082.phpt]
PASS IBM-DB2: db2_conn_errormsg() - wrong database alias[tests/test_090.phpt]
PASS IBM-DB2: db2_conn_errormsg() - wrong username[tests/test_091.phpt]
PASS IBM-DB2: db2_conn_errormsg() - wrong password[tests/test_092.phpt]
PASS IBM-DB2: db2_num_fields() - select - delete - insert[tests/test_100.phpt]
PASS IBM-DB2: db2_num_fields() - insert, delete[tests/test_101.phpt]
PASS IBM-DB2: db2_num_fields() - select[tests/test_102.phpt]
PASS IBM-DB2: db2_num_fields() - select 2[tests/test_103.phpt]
PASS IBM-DB2: db2_field_num()[tests/test_110.phpt]
PASS IBM-DB2: db2_field_num() - add. col.[tests/test_111.phpt]
PASS IBM-DB2: db2_field_num() - colnames diff. case[tests/test_112.phpt]
PASS IBM-DB2: db2_field_name()[tests/test_120.phpt]
PASS IBM-DB2: db2_field_name() - add. col.[tests/test_121.phpt]
PASS IBM-DB2: db2_field_name() - colnames diff. case[tests/test_122.phpt]
PASS IBM-DB2: db2_field_name() - by position[tests/test_123.phpt]
PASS IBM-DB2: db2_field_name() - by position 2[tests/test_124.phpt]
PASS IBM-DB2: db2_field_name() - by position 3[tests/test_125.phpt]
PASS IBM-DB2: db2_prepare / db2_execute: SELECT statement[tests/test_130.phpt]
PASS IBM-DB2: db2_prepare / db2_execute: SELECT statement with parameter[tests/test_131.phpt]
PASS IBM-DB2: db2_execute statement with array of multiple parameters[tests/test_132.phpt]
PASS IBM-DB2: db2_execute with excessively long input parameters[tests/test_133.phpt]
PASS IBM-DB2: db2_bind_param: SELECT statement[tests/test_140.phpt]
PASS IBM-DB2: db2_bind_param: SELECT statement (multiple params)[tests/test_141.phpt]
PASS IBM-DB2: db2_bind_param: SELECT statement (multiple params)[tests/test_142.phpt]
PASS IBM-DB2: db2_bind_param: INSERT statement - NULL parameter[tests/test_143.phpt]
PASS IBM-DB2: db2_bind_param: INSERT statement (one param) - DB2_PARAM_FILE[tests/test_144.phpt]
PASS IBM-DB2: Bind and retrieve NULL and empty string values[tests/test_145.phpt]
PASS IBM-DB2: Call a stored procedure with IN and OUT parameters[tests/test_146.phpt]
PASS IBM-DB2: db2_fetch_assoc() - simple select 1[tests/test_150.phpt]
PASS IBM-DB2: db2_fetch_assoc() - simple select 2[tests/test_151.phpt]
PASS IBM-DB2: db2_fetch_assoc() - simple select 3[tests/test_152.phpt]
PASS IBM-DB2: db2_fetch_assoc() - simple select 4[tests/test_153.phpt]
PASS IBM-DB2: db2_fetch_assoc() - simple select 6[tests/test_155.phpt]
PASS IBM-DB2: db2_fetch_assoc() - nested selects 1[tests/test_156.phpt]
PASS IBM-DB2: db2_fetch_assoc() - positioned with scrollable cursor[tests/test_157.phpt]
PASS IBM-DB2: db2_fetch_assoc() - positioned without scrollable cursor (error)[tests/test_157a.phpt]
PASS IBM-DB2: db2_fetch_assoc() - positioned with scrollable cursor[tests/test_157b.phpt]
PASS IBM-DB2: db2_fetch_assoc() - nested selects 2[tests/test_158.phpt]
PASS IBM-DB2: db2_fetch_assoc() - several rows[tests/test_159.phpt]
PASS IBM-DB2: db2_fetch_assoc() - several rows 2[tests/test_159a.phpt]
PASS IBM-DB2: db2_fetch_both()[tests/test_160.phpt]
PASS IBM-DB2: db2_fetch_both() - nested selects 1[tests/test_161.phpt]
PASS IBM-DB2: db2_fetch_both() - nested selects 2[tests/test_162.phpt]
PASS IBM-DB2: db2_stmt_errormsg()[tests/test_180.phpt]
PASS IBM-DB2: db2_columns() - 1 - table[tests/test_190.phpt]
PASS IBM-DB2: db2_columns() - 2 - table[tests/test_191.phpt]
PASS IBM-DB2: db2_columns() - 3 - table[tests/test_192.phpt]
PASS IBM-DB2: retrieve CLOB columns: forward-only cursor[tests/test_193.phpt]
PASS IBM-DB2: retrieve CLOB columns: scrollable cursor[tests/test_194.phpt]
PASS IBM-DB2: Multiple result sets (uniform column definitions)[tests/test_200.phpt]
PASS IBM-DB2: Multiple result sets (different column definitions)[tests/test_201.phpt]
PASS IBM-DB2: db2_field_display_size() - 1[tests/test_210.phpt]
PASS IBM-DB2: db2_field_display_size() - 2[tests/test_211.phpt]
PASS IBM-DB2: db2_field_display_size() - 3[tests/test_212.phpt]
PASS IBM-DB2: db2_field_display_size() - 4[tests/test_213.phpt]
PASS IBM-DB2: db2_pconnect() - test persistent connection[tests/test_220.phpt]
PASS IBM-DB2: db2_pconnect() - test 500 persistent connections[tests/test_221.phpt]
PASS IBM-DB2: db2_field_type() - by position[tests/test_230.phpt]
PASS IBM-DB2: db2_field_type() - by name[tests/test_231.phpt]
PASS IBM-DB2: db2_field_type() - by position and name[tests/test_232.phpt]
PASS IBM-DB2: db2_field_width() - by position and name[tests/test_240.phpt]
PASS IBM-DB2: db2_field_width() - by position and name 2[tests/test_241.phpt]
PASS IBM-DB2: db2_free_result() - 1[tests/test_250.phpt]
PASS IBM-DB2: db2_free_result() - 2[tests/test_251.phpt]
PASS IBM-DB2: db2_fetch_object()[tests/test_260.phpt]
PASS IBM-DB2: db2_fetch_object() -- access[tests/test_261.phpt]
PASS IBM-DB2: db2_server_info()[tests/test_300.phpt]
PASS IBM-DB2: db2_client_info()[tests/test_310.phpt]
PASS IBM-DB2: PECL bug 6561 -- returning NULL values from column functions[tests/test_6561.phpt]
PASS IBM-DB2: PECL bug 6572 -- SQL strings containing NULL characters[tests/test_6572.phpt]
PASS IBM-DB2: PECL bug 6755 -- Extra null character on result from CLOB column[tests/test_6755.phpt]
PASS IBM-DB2: PECL bug 6792 -- db2_field_type returns 'string' for date, time, and timestamp[tests/test_6792.phpt]
TOTAL TIME: 01:36
124 PASSED TESTS
0 SKIPPED TESTS
sslgm110:/usr/local/src/php-5.1.2/ext/ibm_db2#
 [2006-03-27 10:34 UTC] kfbombar at us dot ibm dot com
This bug has been fixed in CVS.

In case this was a documentation problem, the fix will show up at the
end of next Sunday (CET) on pecl.php.net.

In case this was a pecl.php.net website problem, the change will show
up on the website in short time.
 
Thank you for the report, and for helping us make PECL better.


 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 05:01:33 2024 UTC