NetTalk Central

NetTalk Web Server => Web Server - Ask For Help => Topic started by: Keith on May 13, 2014, 07:59:16 PM

Title: Where to put user data?
Post by: Keith on May 13, 2014, 07:59:16 PM
Sorry for going over old ground, I know that this has been discussed before, but . . .

Suppose I have a single table which can hold records by user.  There seems to be two approaches to architecting this



If there was only a 'few' users - say 1000 and a few records per user, say, 10, then a single keyed file looks like it would work ok.  But 1000 subdirectories - is that feasible?

On the other hand, having all of the records in a single file is a bit scary (can anyone provide solace for this ill feeling!)

So, what's best practice?  What has been done and what are your experiences?  Are there any rules of thumb?  And lastly, what's the best way of going the 'sub-directory' routs where you could have lots of sub-dirs. active at any time - how does that work?

Thanks

Keith
Title: Re: Where to put user data?
Post by: kevin plummer on May 13, 2014, 09:19:42 PM
with that number of users and few records I would favor 1 DB using SQL not TPS
Title: Re: Where to put user data?
Post by: Keith on May 14, 2014, 01:57:21 PM
Kevin

You've raised an interesting point.  The problem is that when we publish this application on the Internet (its not an in-house Intranet app) we don't know what the uptake will be.  We hope it will be successful and that could mean 1000 users or more - who knows!

So, what I don't want to do is to launch with TPS files and find shortly that there is a lack of robustness or control.  So, a couple of questions:


Thanks

Keith
Title: Re: Where to put user data?
Post by: Devan on May 14, 2014, 04:40:45 PM
Keith,

We went through a similar thought process here with a project a couple of years ago.  We went with the single SQL database with unique user IDs, and glad we did.

MySQL is our database solution for nearly all our NetTalk proejct now.  We only use MS-SQL whenever the clients specifically request it to suit their network requirements.  We never use TPS anymore for NetTalk sites.

One of the biggest benefits we found with a single database table, was that it made it really easy for US to administrate and to check user activity levels etc.  We could easily tell which users were more active than other, plus run other periodic metrics and statistics in the database because all the data was in one place.  Trying to do that over a thousand separate sets of data would have been a nightmare.

Hope this helps.

Devan
Title: Re: Where to put user data?
Post by: Keith on May 14, 2014, 10:44:09 PM
Devan, thanks for your comments.

Yes, it is obvious now that we need to have one repository for the data.  The other approach - to have separate repositories would only make sense (for a single centralised app) if there were a few large users that were unrelated.

So, the question then is TPS or SQL and I can see that the preference is for SQL so some qualifying questions if I may regarding a SQL choice:


Thanks

Keith
Title: Re: Where to put user data?
Post by: rainerwallenius on May 15, 2014, 11:10:31 PM
Hi Keith,

I have not changed my database to (any)SQL. Partly because the SQL-backend needs a completely different approach and we have no method of controlling what the end users do with the database. I have tested changing all tables to MSSQL and the software runs nicely "out of the box" - no changes needed. (of course there are some nonos like testing for eof but that is not good practice anyway...). I do have some custoers running SQL-versions of the software but that is for "company policy" -reasons.

Support and control of data is the reason I have chosen to stick with tps. And none of us is a SQL guru either so that clearly is a factor  ;)

We have a customer that manage over 3000 customers payroll. Every customers data is in a separate directory. This is a bit extreme for us but there has been no problem at all with this approach. On the contrary, separate directories have given maximium flexibility for us. Easy to copy etc. Great for support also.

Just some thoughts

:: rainer