You could consider adding a new column to your joining table that contains a
tinyint. By default the value of that field is 0 (which indicates wants) but
changes to 1 when he owns it. This assumes that someone can no longer 'want'
something when they already 'own' it.
Jeremy Burns
Class Outfit
Thanks for replies... I added a two boolean columns to join table for
owns and wants
Thanks again!!
On Jan 13, 3:13 am, Jeremy Burns | Class Outfit
jeremybu...@classoutfit.com wrote:
You could consider adding a new column to your joining table that contains a
tinyint. By default the value of
On Thu, Jan 13, 2011 at 3:55 PM, mklappen mklap...@gmail.com wrote:
Thanks for replies... I added a two boolean columns to join table for
owns and wants
You might be interested in modelizing the join table like this:
http://book.cakephp.org/view/1650/hasMany-through-The-Join-Model
Also, as
Hi All
I'm having a little difficulty conceptualizing the relationships when
setting up a database/models, for a app I'm starting to develop. If
I'm creating a basic inventory management application I have the
following:
Table Name | Columns
users | id, user_name, email, etc...
items | id, name,
It all depends!
What is the requirement for owning items?
Can a user own more than one of the same item?
What is the requirement for wanting items?
Can a user want more than one of the same item?
Can a want record expire - ie. the user wants the item, but only if
the user can get it within X
If you go with the status columns you need two boolean columns one for own
and one for want, its a possible solution.
If you want to use two table you can create users_want and users_own.
The relation for each table should looks like it would be for items_users.
The reason to prefer one