xref: /PHP-8.2/ext/oci8/tests/coll_004_func.phpt (revision b5a14e6c)
1--TEST--
2oci_collection_assign()
3--EXTENSIONS--
4oci8
5--SKIPIF--
6<?php
7$target_dbs = array('oracledb' => true, 'timesten' => false);  // test runs on these DBs
8require(__DIR__.'/skipif.inc');
9?>
10--FILE--
11<?php
12
13require __DIR__."/connect.inc";
14require __DIR__."/create_type.inc";
15
16$coll1 = oci_new_collection($c, $type_name);
17$coll2 = oci_new_collection($c, $type_name);
18
19var_dump(oci_collection_append($coll1, 1));
20
21var_dump(oci_collection_assign($coll2, $coll1));
22
23var_dump(oci_collection_element_get($coll2, 0));
24
25echo "Done\n";
26
27require __DIR__."/drop_type.inc";
28
29?>
30--EXPECT--
31bool(true)
32bool(true)
33float(1)
34Done
35