Welcome aboard! We are happy you are here and wish you good net-raft!
// put symbol @ before command
<?php
@$id_connect = odbc_connect("database","client","password");
if (!$id_connect)
{
echo "The connect is refused";exit();
}
@$id_sql = odbc_exec($id_connect, " SELECT * FROM test_db");
if (!$id_sql ) {echo "SQL Error!";exit();};
while(odbc_fetch_row($id_sql))
{
echo odbc_result($id_sql, "column1");
echo odbc_result($id_sql, "column2");
}
odbc_close($id_connect );
?>
The most helpful PHP solutions
detect browser phpPHP Click to see more ... 4.6K 408