Problem with result of a query in mysql

0

I make the following query, to be shown in a table.

$qry= "select  round(b.monto_final_adelantado*100/sum(a.monto) ) as por 
       from fc_facturas a inner join rc_proyectos b on a.id_proyecto = 
       b.id_proyecto where b.id_proyecto =".$idpro;
$stmt = $bd->ejecutar($qry);
$row = mysqli_fetch_array($stmt,MYSQLI_BOTH);
$prc = $row['por'];
return $prc; 

In mysql workbench it gives me the correct result, however when I show the result by php / html it returns me only "0".

    
asked by sektor 03.11.2017 в 21:46
source

0 answers