I have table with data about tasks like Id, Name, Date, WorkerId, VehicleId (and more 50 fields).
I would like to build orders module that will aloow users insert tasks as an order.
An order contains subset fields from task, for example WorkerId and VehicleId only (as I said – there are more then 50 fields in tasks table).
Since each user can choose his fields definition that compose an order – I have to duplicate the tasks table and name it orders table.
Because the huge size (in terms of fields) of tasks table, I want to avoid duplicate it. Is there any possible way to store order data that not include create huge table like tasks table?
P.S. I don’t want to store the orders in tasks table because:
1. there will be many orders that might affect performance.
2. there are many many tasks already.
It’s hard to tell for sure from your description, but it sounds like you want to treat the columns from the table “tasks” as line items of an order.
Having said that, though, I have to say that
order tasks, but
users order one or two columns from a
table of tasks.
Especially to just order one or two id numbers from a table of tasks–WTF does that mean, anyway?