count referers in database

Results 1 to 2 of 2

Thread: count referers in database

  1. #1
    Join Date
    Dec 1969

    Default count referers in database

    How can i check a database with urls of referers how many times each referer has send a visitor to my site?<BR>First i write a http-referer to my database with date and time.<BR>But now i want a page that shows each different url (referer) with the count of visitors from that referer.<BR><BR>Thanks in advance,<BR>Rob<BR>

  2. #2
    Join Date
    Dec 1969

    Default GROUP BY

    SELECT referer, COUNT(*) As refererCount<BR>FROM yourTable<BR>GROUP BY referer<BR>ORDER BY [see below]<BR><BR>If you want the results ordered by referer, use <BR> ORDER BY 1<BR>or<BR> ORDER BY referer<BR>If you want the results ordered by largest number of references first, use<BR> ORDER BY 2 DESC<BR>or (except with Access)<BR> ORDER BY refererCount DESC<BR><BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts