I have a coworker who is planning a database for a new app that will have several tables with over 30 fields each. Is this excessive? Maybe I'm just not enterprisey enough to understand.
Edit: Also, a lot of the fields are option-type sort of things (like on a request form, would you like your widget to be yellow or green, he has a field for 'colour' with an enum). It's quite likely that these will be added to or removed over time. I haven't really done database design and try to stay away from it myself, so maybe I'm being completely stupid, but surely there's a better way of doing this??
In Access, you can define up to 255 fields in a table. If you create 255 fields and then delete 10, Access does not release the fields from the internal column count. Also, for every field whose properties you modify, Access creates a new field and does not release the original field from the internal column count.
There isn't a number that's too many. That said, it sounds like, based on your description, that you're not dealing with a properly structured table. 180 columns to define a user and 280 columns to define a thing... That can't possibly be normalized or a fact table.
Aside from the sanity of it, what if any is the technical impact of just adding more and more fields? Hi Shane, Technically, MySQL can handle up to 64K (65,535) fields on a table.
The most obvious sign a table requires normalization that I've seen is fields ending with integers: CouponCode1, CouponCode2, CouponCode3.. you get the point. There will be exceptions to the rule as always though.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With