![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
This is a post from comp.databases.mysql: let's say I want to ask a survey question, with checkboxes: What animals do you like? [] giraffe [] elephant [] donkey ... I'd possibly create a single column named "like" and store each response as a comma delimited string: giraffe,donkey elephant,donkey etc But further, let's say I have a question with checkboxes and also radio buttons: Please select which animals you own, and tell us how much you like each: [] cat () low () medium () high [] dog () low () medium () high [] rat () low () medium () high ... What's the best table design to store that? E.g., I could have a column named "own" and another column named "rate". Or I could have a column named "cat" which might contain: yes,low and another column named "dog" which might contain: no and another column named "rat" which might contain: yes,high etc. But neither of those seems quite right to me. I'm obviously thinking of using one flat table for the whole survey, is that a very wrong thing to do? I'm assuming that using a flat table will naturally make it easier to export in spreadsheet format. I'm also not concerned about the memory usage of a flat file. If you could provide 10 prescriptive design rules to a front-end developer, what would they be? Or just 5? Evan |
#3
| |||
| |||
|
|
This is a post from comp.databases.mysql: let's say I want to ask a survey question, with checkboxes: What animals do you like? [] giraffe [] elephant [] donkey ... I'd possibly create a single column named "like" and store each response as a comma delimited string: giraffe,donkey elephant,donkey etc But further, let's say I have a question with checkboxes and also radio buttons: Please select which animals you own, and tell us how much you like each: [] cat () low () medium () high [] dog () low () medium () high [] rat () low () medium () high ... What's the best table design to store that? E.g., I could have a column named "own" and another column named "rate". Or I could have a column named "cat" which might contain: yes,low and another column named "dog" which might contain: no and another column named "rat" which might contain: yes,high etc. But neither of those seems quite right to me. I'm obviously thinking of using one flat table for the whole survey, is that a very wrong thing to do? I'm assuming that using a flat table will naturally make it easier to export in spreadsheet format. I'm also not concerned about the memory usage of a flat file. If you could provide 10 prescriptive design rules to a front-end developer, what would they be? Or just 5? |
#4
| |||
| |||
|
|
Evan Keel wrote: This is a post from comp.databases.mysql: let's say I want to ask a survey question, with checkboxes: What animals do you like? [] giraffe [] elephant [] donkey ... I'd possibly create a single column named "like" and store each response as a comma delimited string: giraffe,donkey elephant,donkey etc But further, let's say I have a question with checkboxes and also radio buttons: Please select which animals you own, and tell us how much you like each: [] cat () low () medium () high [] dog () low () medium () high [] rat () low () medium () high ... What's the best table design to store that? E.g., I could have a column named "own" and another column named "rate". Or I could have a column named "cat" which might contain: yes,low and another column named "dog" which might contain: no and another column named "rat" which might contain: yes,high etc. But neither of those seems quite right to me. I'm obviously thinking of using one flat table for the whole survey, is that a very wrong thing to do? I'm assuming that using a flat table will naturally make it easier to export in spreadsheet format. I'm also not concerned about the memory usage of a flat file. If you could provide 10 prescriptive design rules to a front-end developer, what would they be? Or just 5? 1. Learn the fundamentals 2. See 1 3. See 1 4. See 1 5. See 1 |
#5
| |||
| |||
|
|
"Bob Badour" <bbadour (AT) pei (DOT) sympatico.ca> wrote in message news:46d6129b$0$4056$9a566e8b (AT) news (DOT) aliant.net... Evan Keel wrote: This is a post from comp.databases.mysql: let's say I want to ask a survey question, with checkboxes: What animals do you like? [] giraffe [] elephant [] donkey ... I'd possibly create a single column named "like" and store each response as a comma delimited string: giraffe,donkey elephant,donkey etc But further, let's say I have a question with checkboxes and also radio buttons: Please select which animals you own, and tell us how much you like each: [] cat () low () medium () high [] dog () low () medium () high [] rat () low () medium () high ... What's the best table design to store that? E.g., I could have a column named "own" and another column named "rate". Or I could have a column named "cat" which might contain: yes,low and another column named "dog" which might contain: no and another column named "rat" which might contain: yes,high etc. But neither of those seems quite right to me. I'm obviously thinking of using one flat table for the whole survey, is that a very wrong thing to do? I'm assuming that using a flat table will naturally make it easier to export in spreadsheet format. I'm also not concerned about the memory usage of a flat file. If you could provide 10 prescriptive design rules to a front-end developer, what would they be? Or just 5? 1. Learn the fundamentals 2. See 1 3. See 1 4. See 1 5. See 1 What are the fundamentals? Can you list 5 basic rules of thumb? Heuristics? |
#6
| |||
| |||
|
|
Bob Badour wrote: What are the rules of thumb of addition? surely you mean rules of fingers! |
#7
| |||
| |||
|
|
Bob Badour wrote: Evan Keel wrote: ... 1. Learn the fundamentals 2. See 1 3. See 1 4. See 1 5. See 1 What are the fundamentals? Can you list 5 basic rules of thumb? Heuristics? The fundamentals are the basic principles. They are neither rules of thumb nor heuristics. What are the rules of thumb of addition? shurely you mean rules of fingers! |
#8
| |||
| |||
|
|
"paul c" <toledobythe... (AT) oohay (DOT) ac> wrote in message news:AjqBi.106792$rX4.38768 (AT) pd7urf2no (DOT) .. Bob Badour wrote: Evan Keel wrote: ... 1. Learn the fundamentals 2. See 1 3. See 1 4. See 1 5. See 1 What are the fundamentals? Can you list 5 basic rules of thumb? Heuristics? The fundamentals are the basic principles. They are neither rules of thumb nor heuristics. What are the rules of thumb of addition? shurely you mean rules of fingers! That's only if you are adding digitally! |

#9
| |||
| |||
|
|
This is a post from comp.databases.mysql: let's say I want to ask a survey question, with checkboxes: What animals do you like? [] giraffe [] elephant [] donkey ... I'd possibly create a single column named "like" and store each response as a comma delimited string: giraffe,donkey elephant,donkey etc But further, let's say I have a question with checkboxes and also radio buttons: Please select which animals you own, and tell us how much you like each: [] cat () low () medium () high [] dog () low () medium () high [] rat () low () medium () high ... What's the best table design to store that? E.g., I could have a column named "own" and another column named "rate". Or I could have a column named "cat" which might contain: yes,low and another column named "dog" which might contain: no and another column named "rat" which might contain: yes,high etc. But neither of those seems quite right to me. I'm obviously thinking of using one flat table for the whole survey, is that a very wrong thing to do? I'm assuming that using a flat table will naturally make it easier to export in spreadsheet format. I'm also not concerned about the memory usage of a flat file. If you could provide 10 prescriptive design rules to a front-end developer, what would they be? Or just 5? Evan You guys are so smug and clever. I was looking for real examples: When |
#10
| |||
| |||
|
|
"Evan Keel" <evankeel (AT) sbcglobal (DOT) net> wrote in message news:EbnBi.1216$3Y1.852 (AT) newssvr17 (DOT) news.prodigy.net... This is a post from comp.databases.mysql: let's say I want to ask a survey question, with checkboxes: What animals do you like? [] giraffe [] elephant [] donkey ... I'd possibly create a single column named "like" and store each response as a comma delimited string: giraffe,donkey elephant,donkey etc But further, let's say I have a question with checkboxes and also radio buttons: Please select which animals you own, and tell us how much you like each: [] cat () low () medium () high [] dog () low () medium () high [] rat () low () medium () high ... What's the best table design to store that? E.g., I could have a column named "own" and another column named "rate". Or I could have a column named "cat" which might contain: yes,low and another column named "dog" which might contain: no and another column named "rat" which might contain: yes,high etc. But neither of those seems quite right to me. I'm obviously thinking of using one flat table for the whole survey, is that a very wrong thing to do? I'm assuming that using a flat table will naturally make it easier to export in spreadsheet format. I'm also not concerned about the memory usage of a flat file. If you could provide 10 prescriptive design rules to a front-end developer, what would they be? Or just 5? Evan You guys are so smug and clever. I was looking for real examples: When nulls are ok. When 2 tables have the same key. |
![]() |
| Thread Tools | |
| Display Modes | |
| |