- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
Oh, my god. I nearly hurt myself reading this. You need to add a disclaimer...
Admin
How about adding a column for data type and field length. Come to think of it there are a lot more attributes you could add too.
Works great as a standardized lookup solution though. I can't tell you how many times I have been annoyed by a database with a handful of core tables and about 50 lookups. All of them named pairs.
Admin
This #@$! nightmare is so bad it has a name --EAV (entity, attribute, value) design.
Admin
this is the most creative table design i have come across
Admin
Of course, call me crazy, but couldn't you use systables and syscolumns?
I'm no BrainBench (tm) expert, but it just seems to me...
Admin
This kind of design cannot handle "NOT NULLS" and other restrictions unless you write triggers on each column.
Admin
Hey I have this great idea why dont we create a system that allows us to specify columns and tables and values for those columns. I even came up with a great name for it. I'll call it a database. And the best part is we can reimplement this "database" on a database. Then we can do it again. I mean seriously if your going to go through the trouble of doing this, why dont you just keep on going. Why not have a table that is tbl that has the same columns that define it for tblStaffDirectory. I mean you never know when we might want to add another column to tblStaffDirectory.
Admin
I first thought hang on this is just a open schema - apparently this is a real technique. But then I looked at the column names and thought - No
Admin
Whoa. That's like RDF without the tools to deal with RDF.
Admin
We tried this once and ended up reproducing most of the syscolumns table... :)
Admin
<font size="-1"><font color="#008000">protege.stanford.edu uses exactly this strategy.
</font></font>
Admin
Am I just being stupid here, or is this not just the data dictionary combined with the actual data?
metadata and data all in the same pretty little package... yeuch
Admin
My former employer's flagship software used a layout startlingly similar to this. It was made by outsourced developers, and now I think it's your fault.
I hate you.
Admin
There's a lot more that's wrong with this design than a simple inability to handle "NOT NULL"s, honey.
Admin
http://web.archive.org/web/20150505094235/http://www.papadimoulis.com/alex/tblStaffDirectory.gif