Hi Guys
How do I check whether a select statement returns a value or not.
cnx = odbc_connect( "agent", "", "" );
if( ! $cnx ) {
Error_handler( "Error in odbc_connect" , $cnx );
}
echo "$msg \n";
odbc_close( $cnx);
exit();
}
{ $sql = "select * from members_table where name = 'david'";
$cur = odbc_exec( $cnx, $sql);
if(odbc_num_rows($cur)<=0) {
//return;
//Error_handler( "Error in odbc_exec( no cursor returned ) " , $cnx );
}
$nombreligne = odbc_num_rows($cur);
the $nomberligne variable always returns -1