I've been building the retail web site, going along and thinking it through. As I've been noodling it through, I've grown increasingly uneasy with my original database schema. Started to look more like spaghetti than intelligent design. One of my favorite development tools is Microsoft Word's outline view. You can access it by going to "View/Outline" in the menu. Here, you can create a quick and easily editable outline for your thoughts. There's a custom toolbar that comes with this view. Be sure to toggle off "Show Formatting" in the toolbar. The default is a bunch of funky text and frankly it boggles my mind why those font choices are the default... Databases work best when they model real life relationships and attributes. Which seems obvious on its face, but here's where it becomes a matter of how you view things. Where do you associate, for example, the discount? Obviously, it's associated at the time of ordering. But is it on an item level or on the order level? After a lot of twisting and turning about it, here's my outline: And so with that, I'll be undoing and redoing some of my work on the web site. Interesting puzzles, these are... |