Jump to content

actually, some help with a db layout...


glennn.php

Recommended Posts

i'd love some help with a complex (for me) db layout

 

for each registered client, i have 17 forms - Categories, each with as many as 24 values - Items, to be stored.

 

i was advised to create a Cats table, with cat_id and cat_name, and an items table, with cat_id, item_id, and item_name, and an amounts table, with client_id, cat_id, item_id, amount ... but this seems a bit obtuse.

 

could someone tell me if there's a simpler way to store such data? i've become a bit confused now...

 

:o)

 

thanks much

 

GN

Link to comment
Share on other sites

Hi,

 

it depends what you actually need to store, i mean...

i was advised to create a Cats table, with cat_id and cat_name, and an items table, with cat_id, item_id, and item_name, and an amounts table, with client_id, cat_id, item_id, amount ... but this seems a bit obtuse.

...if you dont need them, dont have them? why so many tables? is there a way to "merge" columns from tables to make just a couple of tables? Without knowing exactly whats on your forms and how they are used i can only speculate but what about:

 

1 form for all your users (name, email, address etc etc)

1 form for all your users items (made_by, item_name, item_price etc etc)

and whatever else (like i said not sure what else you have there)

 

but like rather than having a seperate table for each cat (assuming thats category) just have the one table but define which cat it belongs to maybe in the second column (the first being a item_id of somesort for easy referencing)

 

hope that is somwhat helpful

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.