summaryrefslogtreecommitdiff
path: root/ext/oci8/tests/bug36010.phpt
blob: ec382d27ba08e8baa3e98efe9acd3c651f2dbfaf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--TEST--
Bug #36010 (Crash when executing SQL statement with lob parameter twice)
--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';

function f($conn)
{
	$sql =  "begin :p_clob := 'lob string'; end;";
	$stid = oci_parse($conn, $sql);
	$clob = oci_new_descriptor($conn, OCI_D_LOB);
	oci_bind_by_name($stid, ":p_clob", $clob, -1, OCI_B_CLOB);
	$r = oci_execute($stid, OCI_DEFAULT);
}

f($c);
f($c);

echo "Done\n";

?>
--EXPECT--
Done