1--TEST-- 2odbc_data_source(): Basic test 3--SKIPIF-- 4<?php 5 include 'skipif.inc'; 6 if (odbc_data_source($conn, SQL_FETCH_FIRST) === NULL) { 7 die("skip no data sources defined on this system"); 8 } 9?> 10--FILE-- 11<?php 12 13include 'config.inc'; 14 15$conn = odbc_connect($dsn, $user, $pass); 16 17try { 18 var_dump(odbc_data_source($conn, NULL)); 19} catch (\ValueError $e) { 20 echo $e->getMessage() . \PHP_EOL; 21} 22var_dump(odbc_data_source($conn, SQL_FETCH_FIRST)); 23 24?> 25--EXPECTF-- 26odbc_data_source(): Argument #2 ($fetch_type) must be either SQL_FETCH_FIRST or SQL_FETCH_NEXT 27array(%d) { 28%a 29} 30