osdir.com
mailing list archive

Subject: cvs: pecl /ibm_db2/tests prepare.inc - msg#00059

List: php.pecl.cvs

Date: Prev Next Index Thread: Prev Next Index
kfbombar Mon Apr 10 14:52:36 2006 UTC

Modified files:
/pecl/ibm_db2/tests prepare.inc
Log:
Dropping tables for additional test cases

http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/prepare.inc?r1=1.8&r2=1.9&diff_format=u
Index: pecl/ibm_db2/tests/prepare.inc
diff -u pecl/ibm_db2/tests/prepare.inc:1.8 pecl/ibm_db2/tests/prepare.inc:1.9
--- pecl/ibm_db2/tests/prepare.inc:1.8 Wed Apr 5 17:48:31 2006
+++ pecl/ibm_db2/tests/prepare.inc Mon Apr 10 14:52:36 2006
@@ -24,6 +24,14 @@
$drop = 'DROP TABLE xmlTest';
$result = @db2_exec($prepconn, $drop);

+// Drop the test table for primary keys
+$drop = 'DROP TABLE test_primary_keys';
+$result = @db2_exec($prepconn, $drop);
+
+// Drop the test table for foreign keys
+$drop = 'DROP TABLE test_foreign_keys';
+$result = @db2_exec($prepconn, $drop);
+
// Create the test table
$create = 'CREATE TABLE animals (id INTEGER, breed VARCHAR(32), name CHAR(16),
weight DECIMAL(7,2))';
$result = db2_exec($prepconn, $create);



Was this page helpful?
Yes No
Thread at a glance:

Previous Message by Date: click to view message preview

cvs: pecl /pdo_ids informix_driver.c

kfbombar Mon Apr 10 13:49:12 2006 UTC Modified files: /pecl/pdo_ids informix_driver.c Log: Fix SEGSEV in process_pdo_error http://cvs.php.net/viewcvs.cgi/pecl/pdo_ids/informix_driver.c?r1=1.6&r2=1.7&diff_format=u Index: pecl/pdo_ids/informix_driver.c diff -u pecl/pdo_ids/informix_driver.c:1.6 pecl/pdo_ids/informix_driver.c:1.7 --- pecl/pdo_ids/informix_driver.c:1.6 Fri Mar 17 23:01:14 2006 +++ pecl/pdo_ids/informix_driver.c Mon Apr 10 13:49:12 2006 @@ -19,7 +19,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: informix_driver.c,v 1.6 2006/03/17 23:01:14 kfbombar Exp $ */ +/* $Id: informix_driver.c,v 1.7 2006/04/10 13:49:12 kfbombar Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -537,10 +537,10 @@ if (dbh->methods == NULL) { // if we're not fully initialized, we need to force cleanup ourselves. - informix_handle_closer(dbh TSRMLS_CC); zend_throw_exception_ex(php_pdo_get_exception(), 0 TSRMLS_CC, "SQLSTATE=%s, %s: %d %s", conn_res->error_data.sql_state, conn_res->error_data.failure_name, conn_res->error_data.sqlcode, conn_res->error_data.err_msg); + informix_handle_closer(dbh TSRMLS_CC); } }

Next Message by Date: click to view message preview

cvs: pecl /ibm_db2/tests test_023.phpt test_024.phpt test_025.phpt

kfbombar Mon Apr 10 14:53:46 2006 UTC Added files: /pecl/ibm_db2/tests test_023.phpt test_024.phpt test_025.phpt Log: Initial Version http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/test_023.phpt?view=markup&rev=1.1 Index: pecl/ibm_db2/tests/test_023.phpt +++ pecl/ibm_db2/tests/test_023.phpt --TEST-- IBM-DB2: db2_column_privileges -- tests the db2_column_privileges functionality --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php require_once('connection.inc'); $conn = db2_connect($database, $user, $password); if ($conn != 0) { $stmt = db2_column_privileges($conn, NULL, NULL, 'ANIMALS'); $row = db2_fetch_array($stmt); var_dump($row); db2_close($conn); } else { echo db2_conn_errormsg(); printf("Connection failed\n\n"); } ?> --EXPECT-- array(8) { [0]=> NULL [1]=> string(8) "INFORMIX" [2]=> string(7) "ANIMALS" [3]=> string(5) "BREED" [4]=> string(6) "SYSIBM" [5]=> string(8) "INFORMIX" [6]=> string(6) "INSERT" [7]=> string(3) "YES" } http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/test_024.phpt?view=markup&rev=1.1 Index: pecl/ibm_db2/tests/test_024.phpt +++ pecl/ibm_db2/tests/test_024.phpt --TEST-- IBM-DB2: db2_foreign_keys -- tests the db2_foreign_keys functionality --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php require_once('connection.inc'); $conn = db2_connect($database, $user, $password); if ($conn != 0) { $statement = 'CREATE TABLE test_primary_keys (id INTEGER NOT NULL, PRIMARY KEY(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_primary_keys VALUES (1)"; $result = db2_exec($conn, $statement); $statement = 'CREATE TABLE test_foreign_keys (idf INTEGER NOT NULL, FOREIGN KEY(idf) REFERENCES test_primary_keys(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_foreign_keys VALUES (1)"; $result = db2_exec($conn, $statement); $stmt = db2_foreign_keys($conn, NULL, NULL, 'TEST_PRIMARY_KEYS'); $row = db2_fetch_array($stmt); for ($i=0; $i<8; $i++) { echo $row[$i] . "\n"; } db2_close($conn); } else { echo db2_conn_errormsg(); printf("Connection failed\n\n"); } ?> --EXPECT-- INFORMIX TEST_PRIMARY_KEYS ID INFORMIX TEST_FOREIGN_KEYS IDF http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/test_025.phpt?view=markup&rev=1.1 Index: pecl/ibm_db2/tests/test_025.phpt +++ pecl/ibm_db2/tests/test_025.phpt --TEST-- IBM-DB2: db2_primary_keys -- tests the db2_primary_keys functionality --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php require_once('connection.inc'); $conn = db2_connect($database, $user, $password); if ($conn != 0) { $statement = 'CREATE TABLE test_primary_keys (id INTEGER NOT NULL, PRIMARY KEY(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_primary_keys VALUES (1)"; $result = db2_exec($conn, $statement); $statement = 'CREATE TABLE test_foreign_keys (idf INTEGER NOT NULL, FOREIGN KEY(idf) REFERENCES test_primary_keys(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_foreign_keys VALUES (1)"; $result = db2_exec($conn, $statement); $stmt = db2_primary_keys($conn, NULL, NULL, 'TEST_PRIMARY_KEYS'); $row = db2_fetch_array($stmt); for ($i=0; $i<5; $i++) { echo $row[$i] . "\n"; } db2_close($conn); } else { echo db2_conn_errormsg(); printf("Connection failed\n\n"); } ?> --EXPECT-- INFORMIX TEST_PRIMARY_KEYS ID 1

Previous Message by Thread: click to view message preview

cvs: pecl /pdo_ids informix_driver.c

kfbombar Mon Apr 10 13:49:12 2006 UTC Modified files: /pecl/pdo_ids informix_driver.c Log: Fix SEGSEV in process_pdo_error http://cvs.php.net/viewcvs.cgi/pecl/pdo_ids/informix_driver.c?r1=1.6&r2=1.7&diff_format=u Index: pecl/pdo_ids/informix_driver.c diff -u pecl/pdo_ids/informix_driver.c:1.6 pecl/pdo_ids/informix_driver.c:1.7 --- pecl/pdo_ids/informix_driver.c:1.6 Fri Mar 17 23:01:14 2006 +++ pecl/pdo_ids/informix_driver.c Mon Apr 10 13:49:12 2006 @@ -19,7 +19,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: informix_driver.c,v 1.6 2006/03/17 23:01:14 kfbombar Exp $ */ +/* $Id: informix_driver.c,v 1.7 2006/04/10 13:49:12 kfbombar Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -537,10 +537,10 @@ if (dbh->methods == NULL) { // if we're not fully initialized, we need to force cleanup ourselves. - informix_handle_closer(dbh TSRMLS_CC); zend_throw_exception_ex(php_pdo_get_exception(), 0 TSRMLS_CC, "SQLSTATE=%s, %s: %d %s", conn_res->error_data.sql_state, conn_res->error_data.failure_name, conn_res->error_data.sqlcode, conn_res->error_data.err_msg); + informix_handle_closer(dbh TSRMLS_CC); } }

Next Message by Thread: click to view message preview

cvs: pecl /ibm_db2/tests test_023.phpt test_024.phpt test_025.phpt

kfbombar Mon Apr 10 14:53:46 2006 UTC Added files: /pecl/ibm_db2/tests test_023.phpt test_024.phpt test_025.phpt Log: Initial Version http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/test_023.phpt?view=markup&rev=1.1 Index: pecl/ibm_db2/tests/test_023.phpt +++ pecl/ibm_db2/tests/test_023.phpt --TEST-- IBM-DB2: db2_column_privileges -- tests the db2_column_privileges functionality --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php require_once('connection.inc'); $conn = db2_connect($database, $user, $password); if ($conn != 0) { $stmt = db2_column_privileges($conn, NULL, NULL, 'ANIMALS'); $row = db2_fetch_array($stmt); var_dump($row); db2_close($conn); } else { echo db2_conn_errormsg(); printf("Connection failed\n\n"); } ?> --EXPECT-- array(8) { [0]=> NULL [1]=> string(8) "INFORMIX" [2]=> string(7) "ANIMALS" [3]=> string(5) "BREED" [4]=> string(6) "SYSIBM" [5]=> string(8) "INFORMIX" [6]=> string(6) "INSERT" [7]=> string(3) "YES" } http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/test_024.phpt?view=markup&rev=1.1 Index: pecl/ibm_db2/tests/test_024.phpt +++ pecl/ibm_db2/tests/test_024.phpt --TEST-- IBM-DB2: db2_foreign_keys -- tests the db2_foreign_keys functionality --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php require_once('connection.inc'); $conn = db2_connect($database, $user, $password); if ($conn != 0) { $statement = 'CREATE TABLE test_primary_keys (id INTEGER NOT NULL, PRIMARY KEY(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_primary_keys VALUES (1)"; $result = db2_exec($conn, $statement); $statement = 'CREATE TABLE test_foreign_keys (idf INTEGER NOT NULL, FOREIGN KEY(idf) REFERENCES test_primary_keys(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_foreign_keys VALUES (1)"; $result = db2_exec($conn, $statement); $stmt = db2_foreign_keys($conn, NULL, NULL, 'TEST_PRIMARY_KEYS'); $row = db2_fetch_array($stmt); for ($i=0; $i<8; $i++) { echo $row[$i] . "\n"; } db2_close($conn); } else { echo db2_conn_errormsg(); printf("Connection failed\n\n"); } ?> --EXPECT-- INFORMIX TEST_PRIMARY_KEYS ID INFORMIX TEST_FOREIGN_KEYS IDF http://cvs.php.net/viewcvs.cgi/pecl/ibm_db2/tests/test_025.phpt?view=markup&rev=1.1 Index: pecl/ibm_db2/tests/test_025.phpt +++ pecl/ibm_db2/tests/test_025.phpt --TEST-- IBM-DB2: db2_primary_keys -- tests the db2_primary_keys functionality --SKIPIF-- <?php require_once('skipif.inc'); ?> --FILE-- <?php require_once('connection.inc'); $conn = db2_connect($database, $user, $password); if ($conn != 0) { $statement = 'CREATE TABLE test_primary_keys (id INTEGER NOT NULL, PRIMARY KEY(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_primary_keys VALUES (1)"; $result = db2_exec($conn, $statement); $statement = 'CREATE TABLE test_foreign_keys (idf INTEGER NOT NULL, FOREIGN KEY(idf) REFERENCES test_primary_keys(id))'; $result = db2_exec($conn, $statement); $statement = "INSERT INTO test_foreign_keys VALUES (1)"; $result = db2_exec($conn, $statement); $stmt = db2_primary_keys($conn, NULL, NULL, 'TEST_PRIMARY_KEYS'); $row = db2_fetch_array($stmt); for ($i=0; $i<5; $i++) { echo $row[$i] . "\n"; } db2_close($conn); } else { echo db2_conn_errormsg(); printf("Connection failed\n\n"); } ?> --EXPECT-- INFORMIX TEST_PRIMARY_KEYS ID 1
Sign up for updates to this mailing list. email:
Loading Comments...
Home | News | Patents | Sitemap | FAQ | advertise

Advertising by