// 簡單連線
$cnx = odbc_connect('cliente','Administrador','');
//查詢
$SQL_Exec_String = "select * from Clientes";
//執行查詢
$cur = odbc_exec( $cnx, $SQL_Exec_String );
echo "<table border=1><tr><th>身分證字號</th><th>姓名</th>".
"<th>代碼</th><th>城市</th></tr>\n";
while( odbc_fetch_row( $cur ) ) {
$Dni = odbc_result( $cur, 1 );
$Nombre = odbc_result( $cur, 2 );
$codigo = odbc_result( $cur, 3 );
$ciudad = odbc_result( $cur, 4 );
echo "<tr><td>$Dni</td><td>$Nombre</td>".
"<td>$codigo</td><td>$ciudad</td></tr>\n";
}
echo "</table>";