#1 (permalink)  
Old 12-19-2007, 09:19 AM
VOXEL's Avatar
Registered User
 
Join Date: Dec 2007
Posts: 4
Optimizing tables to compare bilions of rows. How?

Dear all,

Currently I am working on a project that has to do with logging
visitors traffic.
Let's say, every time a visitor has visited the website, one row will
be inserted into a table.

Thing is, just like OneStat, Nedstat or whatever, this project
retrieves it's input from a large number of website. This may result
in let's say 1000 rows per minute from the start but probably a hell
of a lot more.

First question is: How many rows can be processed per minute, or
second?


Now my second question is more difficult. I will also need to compare
the results in a guide page, that will compare all the data collected
and for example show, which site has had the most visitors. For the
last day, week, year... whatever.

My problem is that if I would store all data in one table, this table
will very soon be very very large. I don't know the maximum number of
rows that are allowed, but this will sure influence the speed. The
more rows, the longer it will take of course to compare and show
results in the Guide Page. And finaly I will hit the maximum number of
rows anyhow.

What I am thinking of is to automatically generate a table for every
month but I am not sure if this is wise. Will I be able to compare
fast enough after a year? Let's say I have 12 tables and I want to
compare all rows, let's say there are one bilion rows in each
table...

What I actually like to know I think, is how the database of NedStat
is more or less structure. They probably must have over a milion rows
to store every minute... Can anyone tell me how the manage to store
and compare all this data?
_________________
REMOVED YOUR SPAM BEYOTCH!
Reply With Quote

  #2 (permalink)  
Old 12-19-2007, 09:33 AM
Deadeye's Avatar
Moderator
 
Join Date: Aug 2005
Location: San Diego, CA
Posts: 274
Send a message via MSN to Deadeye
first question is what database program are you using, SQL Server, Oracle, mysql? Everyone has diffrent limitations, but all are fast, if you created a new table for each website you'll be fine and trim off data that is older than 1 year, or if you want historical data past that trim it off every 5 years. The queries you will want to do wont take very long on a table with a few million entries.

Wesley

*EDIT* It also depends on how fast the server is as well.. I quad core 3 Ghz Zeon will perform a query on 5 million rows faster than a single core 1 Ghz Processor
__________________
Don't forget to rate me A+++++++++++++++++!!!!!111one for the service you have received.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Need some help aligning tables Jas Programming and Scripting 4 12-07-2007 01:07 AM
HTML tables.. yuppicide Programming and Scripting 2 01-26-2007 05:53 AM
Looking for links (pre-made database tables) curtiss Databases 1 05-08-2006 11:50 AM
Locking Tables Woodhead2k Programming and Scripting 3 01-07-2006 01:56 PM


All times are GMT -5. The time now is 12:06 AM.

 
Bitrix
Clicky Web Analytics
CloudContacts
Maxtango


Subscribe to our feed | add to myYahoo!

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.2.0
© 1997-2007 HTMLCenter