Forum Moderators: open

Message Too Old, No Replies

My biggest idea / project so far.

... would appreciate any input from you guys

         

le_gber

6:07 pm on Mar 24, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I'm planning on building the biggest app I have ever tried building and would appreciate the input from anyone hanging round here.

The project will be a db driven site running PHP/MySql selling other people products - a kind of classified site.

I thought about having two db's - the first one being a kind of filter that would 'protect' the real/live one from people misbehaving.

It would only hold very little info - login details and product description etc... People would be able to ADD stuff to it

The second one would be where I 'approve' each product to be published - which would hold the same type of info but some other as well, like people's contact details etc... People would only be able to SELECT from it and I alone could ADD, UPDATE, DELETE.

Is this a proper way of doing it? or is it just a waste of time and I could achive the same thing using one db and many tables?

Thanks for your feedback

txbakers

6:33 pm on Mar 24, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



one database.

make yourself a little management console screen tied into the db so you can approve/disapprove without having to log into the database each time.

le_gber

9:05 pm on Mar 24, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



a little management console screen tied into the db

how would you go about doing this? A software running on my own pc or a web based one?

Cheers

txbakers

9:46 pm on Mar 24, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



web based. If you're good at PHP you can make screens that let you do all the administrative tasks. Saves you lots of time.

le_gber

9:08 am on Mar 25, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi txbaker

thanks for your input.

I was thinking of having a web based control panel calling the temporary table and for me to just double check the info - and 'approve' it.

I am not great with PHP but this add/approve screen is not rocket science. For the delete I was thinking of running a cron job every morning and deleting all the records who have a date of 'the limit' + 1 day.

Thanks again

FourDegreez

12:56 am on Mar 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Keep the records in the same table(s), just have a status field with several different statuses: New, Approved, Deleted, etc.

Any query that would return records to a user should include WHERE status = 'Approved'

Careful on that, because if you forget to include status in the WHERE clause you could expose records that you don't want to expose.

le_gber

12:08 pm on Mar 29, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



hi fourdegreez,

thanks for your input.

coming back on the DB number would having two DB have an effect on server load or not?

i.e. would running one big DB (lets say 20 tables / 2 of them having +10,000 records) be slower than running 2 DBs (same number of tables but spread over the 2 DBs each table with +10,000 being in a separate DB)

most queries will only be to one of the tables wit +10,000 records

Cheers

topr8

1:08 pm on Mar 29, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



>>10,000 records

this is tiny in db terms, if you are trying to make things quicker by having 2 databases then you won't.

speed things up by optimising your queries, indexing the tables properly and so on.

basically you can test all these things anyway, populate the tables with random data and test to see what is quicker.

txbakers

1:14 pm on Mar 29, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



one database.

one database.

one database.

le_gber

1:30 pm on Mar 29, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



cheers topr8 and txbaker

did I upset you tx ;)?