evanscamman
Registered User.
- Local time
- Today, 03:45
- Joined
- Feb 25, 2007
- Messages
- 274
I've got an ordering database and I keep adding more and more checkboxes to the Orders table...
Authorized,Processed,Confirmed,Shipping,Received,CheckedIn,
RedFlagged,BackOrdered,etc...
I also have a StatusField where I store a calculated value - giving the Order's current status in a nutshell (calculated to speed up queries)
1 = Authorized
2 = Processed
3 = Confirmed, etc...
Each time the order process moves forwards, it's status has to be reevaluated - sometimes this is done in a query, other times in VBA.
My question is:
Would I be better off to shrink all these check boxes down to one Long, define some constants, and use the whole bit flag approach?
I have the feeling that this is more elegant, but would I get into trouble when i try to use the constants within a query?
Would I end up with 42 levels of Iif statements?
(I never call functions from within queries anymore because they are so slow!)
Thanks for your input!
Evan
Authorized,Processed,Confirmed,Shipping,Received,CheckedIn,
RedFlagged,BackOrdered,etc...
I also have a StatusField where I store a calculated value - giving the Order's current status in a nutshell (calculated to speed up queries)
1 = Authorized
2 = Processed
3 = Confirmed, etc...
Each time the order process moves forwards, it's status has to be reevaluated - sometimes this is done in a query, other times in VBA.
My question is:
Would I be better off to shrink all these check boxes down to one Long, define some constants, and use the whole bit flag approach?
I have the feeling that this is more elegant, but would I get into trouble when i try to use the constants within a query?
Would I end up with 42 levels of Iif statements?
(I never call functions from within queries anymore because they are so slow!)
Thanks for your input!
Evan