Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
I need a second opinion!!!!!
All I need is a simple A or B answer. Unless you can think an a better way... I'm always open to new ideas. I'm not sure which way I should go about doing this. OK here it is:
At one spot in the program I'm developing the user can click between three diffrent tabs on a form. Each tab shows them an option of 21 (on each tab) diffrent Permits they can include with the Permit they are about to print. Now this adds up to 63 diffrent Permits that could (God help us) be included with the users Permit. But we also have an option to save each Permit as a Template and these Add-On Permits need to be saved in the Template as well. Not to mention if the user would like to edit the Template I need to load this information. So now I'm stuck.
A) I could add 63 more fields to the database Table and save the name or - ID number of each Add-on Permit that the user selects. But that seems a little extreme considering that this Add-On Permit thing is an option and is not likely to be used most of the time. Plus the table that this needs to be saved in already has 20 some fields in it.
B) Create a string that holds the ID number of each Permit with a defining sign that signals the end of the ID number. IE: if the user selects the first three Permits then the string would hold something like "-1-2-3". Then I could save this string in three fields (one for each tab) and use the "-" sign in code to load the information from a Template. But this seems like alot of extra code and maybe even more overhead.
Right now I think I'm gonna go for choice B but I figured before I typed a bunch of code I should get a second opinion. So tell me what you think I should do. A) Add 63 fields to a table that already contains 23 fields as it is and take the easy way out. or B) Only add 3 fields to this table and save the selected Add-on Permits ID number as a text field with a defining sign between each number.
0 · ·