MySQL Forums
Forum List  »  Newbie

Re: Things like budget approvals (do I need a table for booleans)?
Posted by: Rick James
Date: February 04, 2015 06:39PM

There is no simple 'right' answer.

Do you need to know when it was approved? By whom? Can approval be revoked? Do you need to track the when and who of that, too? If Yes to some of those, then a separate table is possibly better. Revoking approval probably needs the extra table.

Or you could put the when and who of the approval in the main table. At that point, you could get rid of the boolean; instead use "AND who IS NOT NULL".

Are there multiple flags that you need? Do you need to test lots of them at the same time? If so, maybe SET with FIND_IN_SET() or INT with bit operators would be better.

Options: ReplyQuote


Subject
Written By
Posted
Re: Things like budget approvals (do I need a table for booleans)?
February 04, 2015 06:39PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.