2 Sybase-CT sybase_fetch_object
9 /* This file is part of PHP test framework for ext/sybase_ct
20 // {{{ resource fetch_object(resource db, [mixed arg= NULL])
21 // Fetches a resultset and returns it as an object
22 function fetch_object($db, $arg= NULL) {
23 return sybase_fetch_object(sybase_query('select
27 getdate() as "lastchange"
32 $db= sybase_connect_ex();
35 var_export(fetch_object($db)); echo "\n";
37 // Test with userland class
38 var_export(fetch_object($db, 'article')); echo "\n";
41 var_export(fetch_object($db, new article())); echo "\n";
43 // Test with non-existant class
44 var_export(fetch_object($db, '***')); echo "\n";
49 stdClass::__set_state(array(
55 article::__set_state(array(
61 article::__set_state(array(
68 Notice: sybase_fetch_object(): Sybase: Class *** has not been declared in %stest_fetch_object.php on line %d
69 stdClass::__set_state(array(