I’m trying to select something from my database but I do a chart, so for comparating In eed the same value but for the previous years.
Also I’ve done something like that:
$query254="
SELECT SUM(honoraires)
FROM versements
WHERE `date_reception`=DATE_SUB(".$dates3[$i3].", INTERVAL 365 DAY)";
$resultat254 = mysql_query($query254) or die(mysql_error());
$rowing254 = mysql_fetch_array($resultat254); ?>
The thing is that it does not work, In fact it select the values for the same year. Without substracting the 365 days.
So I do not know how to do.
Receive all my Utmost Respect.
SP.
1 Answer