Download src/php/php-src/ext/odbc/tests/bug73725.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 914 Bytes
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/odbc/tests/bug73725.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/ext/odbc/tests/bug73725.phpt
-
curl -L -o bug73725.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/odbc/tests/bug73725.phpt
914 Bytes
| --TEST-- | |
| Bug #73725 Unable to retrieve value of varchar(max) type | |
| --EXTENSIONS-- | |
| odbc | |
| --SKIPIF-- | |
| include 'skipif.inc'; | |
| --FILE-- | |
| include __DIR__ . "/config.inc"; | |
| $conn = odbc_connect($dsn, $user, $pass); | |
| odbc_do($conn, "CREATE TABLE bug73725(i int, txt varchar(max), k int)"); | |
| odbc_do($conn, "INSERT INTO bug73725 VALUES(101,'Any text', 33), (102,'Lorem ipsum dolor', 34)"); | |
| $rc = odbc_do($conn, "SELECT i, txt, k FROM bug73725"); | |
| $r = odbc_fetch_array($rc); | |
| var_dump($r); | |
| $r = odbc_fetch_array($rc); | |
| var_dump($r); | |
| --CLEAN-- | |
| include 'config.inc'; | |
| $conn = odbc_connect($dsn, $user, $pass); | |
| odbc_exec($conn, 'DROP TABLE bug73725'); | |
| odbc_close($conn); | |
| --EXPECT-- | |
| array(3) { | |
| ["i"]=> | |
| string(3) "101" | |
| ["txt"]=> | |
| string(8) "Any text" | |
| ["k"]=> | |
| string(2) "33" | |
| } | |
| array(3) { | |
| ["i"]=> | |
| string(3) "102" | |
| ["txt"]=> | |
| string(17) "Lorem ipsum dolor" | |
| ["k"]=> | |
| string(2) "34" | |
| } | |