Bassically I have 2 tables. 1) visitor information and 2) page view information. Note this has been scaled down to help make since
first query:
Code: Select all
<?php
$result = @mysql_query("SELECT stats_id, etc, etc FROM stats ORDER BY st_id DESC LIMIT 20" );
?>Code: Select all
<?php
$result2 = @mysql_query("SELECT pv_id, COUNT(*) AS tpv FROM statspv WHERE pv_ref_id='$stats_id' GROUP BY pv_ref_id" );
$row = mysql_fetch_array($result2);
$tpv = $row["tpv"];
?>Thanks for any input.
Tim