I'm working on a 3rd party app written in 4.0 and trying to figure out why it's returning a -1. Can someone interpret this code and let me know what's going on.
Thanks!
function GetNewIDFromDB ( &$objDBConn )
{
$objDBConn->ExecuteSQL( "update uniqueid set cur_id=cur_id+1" );
$objDBConn->ExecuteSQL( "select cur_id from uniqueid", 1 );
$j = $objDBConn->FetchRow() ? $objDBConn->ColumnData( "cur_id" ) : -1;
return $j;
}