mirror of
https://github.com/php/php-src.git
synced 2024-10-17 06:22:53 +00:00
37 lines
644 B
PHP
Executable File
37 lines
644 B
PHP
Executable File
--TEST--
|
|
sqlite-oo: sqlite_fetch_column_types
|
|
--SKIPIF--
|
|
<?php # vim:ft=php
|
|
if (!extension_loaded("sqlite")) print "skip"; ?>
|
|
--FILE--
|
|
<?php
|
|
include "blankdb_oo.inc";
|
|
|
|
$db->query("CREATE TABLE strings(a, b INTEGER, c VARCHAR(10), d)");
|
|
$db->query("INSERT INTO strings VALUES('1', '2', '3', 'abc')");
|
|
|
|
var_dump($db->fetchColumnTypes("strings"));
|
|
?>
|
|
--EXPECT--
|
|
array(4) {
|
|
["a"]=>
|
|
string(0) ""
|
|
["b"]=>
|
|
string(7) "INTEGER"
|
|
["c"]=>
|
|
string(11) "VARCHAR(10)"
|
|
["d"]=>
|
|
string(0) ""
|
|
}
|
|
--UEXPECT--
|
|
array(4) {
|
|
[u"a"]=>
|
|
unicode(0) ""
|
|
[u"b"]=>
|
|
unicode(7) "INTEGER"
|
|
[u"c"]=>
|
|
unicode(11) "VARCHAR(10)"
|
|
[u"d"]=>
|
|
unicode(0) ""
|
|
}
|