????JFIF??x?x????'
| Server IP : 79.136.114.73 / Your IP : 216.73.216.57 Web Server : Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.29 OpenSSL/1.0.1f System : Linux b8009 3.13.0-170-generic #220-Ubuntu SMP Thu May 9 12:40:49 UTC 2019 x86_64 User : www-data ( 33) PHP Version : 5.5.9-1ubuntu4.29 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /proc/self/root/home/b8009/php-5.6.22/ext/oci8/tests/ |
Upload File : |
--TEST--
oci_fetch_all() - 2
--SKIPIF--
<?php
$target_dbs = array('oracledb' => true, 'timesten' => false); // test runs on these DBs
require(dirname(__FILE__).'/skipif.inc');
?>
--FILE--
<?php
require dirname(__FILE__)."/connect.inc";
require dirname(__FILE__).'/create_table.inc';
$insert_sql = "INSERT INTO ".$schema."".$table_name." (id, value) VALUES (1,1)";
$s = oci_parse($c, $insert_sql);
for ($i = 0; $i<3; $i++) {
oci_execute($s);
}
oci_commit($c);
$select_sql = "SELECT * FROM ".$schema."".$table_name."";
$s = oci_parse($c, $select_sql);
oci_execute($s);
var_dump(oci_fetch_all($s, $all));
var_dump($all);
oci_execute($s);
var_dump(oci_fetch_all($s, $all, 0, 10, OCI_FETCHSTATEMENT_BY_ROW));
var_dump($all);
oci_execute($s);
var_dump(oci_fetch_all($s, $all, -1, -1, OCI_FETCHSTATEMENT_BY_ROW));
var_dump($all);
oci_execute($s);
var_dump(oci_fetch_all($s, $all, 0, 2, OCI_FETCHSTATEMENT_BY_ROW+OCI_NUM));
var_dump($all);
oci_execute($s);
var_dump(oci_fetch_all($s, $all, 0, 2, OCI_NUM));
var_dump($all);
oci_execute($s);
var_dump(oci_fetch_all($s, $all, 0, 1, OCI_BOTH));
var_dump($all);
require dirname(__FILE__).'/drop_table.inc';
echo "Done\n";
?>
--EXPECT--
int(3)
array(5) {
["ID"]=>
array(3) {
[0]=>
string(1) "1"
[1]=>
string(1) "1"
[2]=>
string(1) "1"
}
["VALUE"]=>
array(3) {
[0]=>
string(1) "1"
[1]=>
string(1) "1"
[2]=>
string(1) "1"
}
["BLOB"]=>
array(3) {
[0]=>
NULL
[1]=>
NULL
[2]=>
NULL
}
["CLOB"]=>
array(3) {
[0]=>
NULL
[1]=>
NULL
[2]=>
NULL
}
["STRING"]=>
array(3) {
[0]=>
NULL
[1]=>
NULL
[2]=>
NULL
}
}
int(3)
array(3) {
[0]=>
array(5) {
["ID"]=>
string(1) "1"
["VALUE"]=>
string(1) "1"
["BLOB"]=>
NULL
["CLOB"]=>
NULL
["STRING"]=>
NULL
}
[1]=>
array(5) {
["ID"]=>
string(1) "1"
["VALUE"]=>
string(1) "1"
["BLOB"]=>
NULL
["CLOB"]=>
NULL
["STRING"]=>
NULL
}
[2]=>
array(5) {
["ID"]=>
string(1) "1"
["VALUE"]=>
string(1) "1"
["BLOB"]=>
NULL
["CLOB"]=>
NULL
["STRING"]=>
NULL
}
}
int(0)
array(0) {
}
int(2)
array(2) {
[0]=>
array(5) {
[0]=>
string(1) "1"
[1]=>
string(1) "1"
[2]=>
NULL
[3]=>
NULL
[4]=>
NULL
}
[1]=>
array(5) {
[0]=>
string(1) "1"
[1]=>
string(1) "1"
[2]=>
NULL
[3]=>
NULL
[4]=>
NULL
}
}
int(2)
array(5) {
[0]=>
array(2) {
[0]=>
string(1) "1"
[1]=>
string(1) "1"
}
[1]=>
array(2) {
[0]=>
string(1) "1"
[1]=>
string(1) "1"
}
[2]=>
array(2) {
[0]=>
NULL
[1]=>
NULL
}
[3]=>
array(2) {
[0]=>
NULL
[1]=>
NULL
}
[4]=>
array(2) {
[0]=>
NULL
[1]=>
NULL
}
}
int(1)
array(5) {
[0]=>
array(1) {
[0]=>
string(1) "1"
}
[1]=>
array(1) {
[0]=>
string(1) "1"
}
[2]=>
array(1) {
[0]=>
NULL
}
[3]=>
array(1) {
[0]=>
NULL
}
[4]=>
array(1) {
[0]=>
NULL
}
}
Done