318422 finish mysql query
N/A
ชำระเงินเมื่อจัดส่ง
Hello,
I need someone to finish this query for me so it works the way I want it to.
The original working query:
$query = "SELECT COUNT(*) as num FROM banners WHERE status=1 AND max>shown";
The query above pulls up 158 banners which is correct.
Now, I need to exclude banners that the user has already clicked on before so they are not displayed again.
banner clicks are tracked in a table called:
bannerviews
id
userid
blid
bannerviews.blid=[url removed, login to view]
I need the query written now to exclude the banner from displaying if
the [url removed, login to view] shows up in [url removed, login to view] where userid=uname
หมายเลขโปรเจค: #2064223