1--TEST--
2PDO_OCI: Bug #69356 (PDOStatement::debugDumpParams() truncates query)
3--SKIPIF--
4<?php
5if (!extension_loaded('pdo') || !extension_loaded('pdo_oci')) die('skip not loaded');
6require(__DIR__.'/../../pdo/tests/pdo_test.inc');
7PDOTest::skip();
8?>
9--FILE--
10<?php
11require(__DIR__ . '/../../pdo/tests/pdo_test.inc');
12
13$db = PDOTest::factory();
14$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, true);
15$stmt = $db->query("
16    SELECT '
17        Dumps the information contained by a prepared statement directly on the output. It will provide the SQL query in use, the number of parameters used (Params), the list of parameters, with their name, type (paramtype) as an integer, their key name or position, and the position in the query (if this is supported by the PDO driver, otherwise, it will be -1).
18        This is a debug function, which dump directly the data on the normal output.
19        Tip:
20        As with anything that outputs its result directly to the browser, the output-control functions can be used to capture the output of this function, and save it in a string (for example).
21        This will only dumps the parameters in the statement at the moment of the dump. Extra parameters are not stored in the statement, and not displayed.
22    ' FROM DUAL
23");
24var_dump($stmt->debugDumpParams());
25?>
26--EXPECT--
27SQL: [844]
28    SELECT '
29        Dumps the information contained by a prepared statement directly on the output. It will provide the SQL query in use, the number of parameters used (Params), the list of parameters, with their name, type (paramtype) as an integer, their key name or position, and the position in the query (if this is supported by the PDO driver, otherwise, it will be -1).
30        This is a debug function, which dump directly the data on the normal output.
31        Tip:
32        As with anything that outputs its result directly to the browser, the output-control functions can be used to capture the output of this function, and save it in a string (for example).
33        This will only dumps the parameters in the statement at the moment of the dump. Extra parameters are not stored in the statement, and not displayed.
34    ' FROM DUAL
35
36Params:  0
37NULL
38