- 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
I've seen long middle initial columns before, somewhere in the life of the product they discover that they need a middle name, or names and change to column length. Column names should be considered the same as section headers in legal contracts, there is no guarantee that either actually describe the content.
Admin
You have to be able to support multi-digit initials; you never know what could happen to the initial standard in the future.3
captcha: damnum
Admin
When I saw "Access Database" I immediately thought of my time at a college radio station, using a similar (or possibly the same) program. The program originally came as a package on two 800MHz Win2k machines. Years later we upgraded to XP and found that we needed a new version of the program, once installed (which was an...eye opening process) we found that the program looked and operated exactly like it's 2k predecessor, complete with crashes and 800x600 resolution. We cut our losses and moved to Rivendell less than a year later.
Admin
Everybody knows that a 255-byte field will be required to support a middle initial once Unicode v.9 comes around.
Admin
Admin
I was disappointed that the last WTF was not referring to the image (in fact an ad) at the end, which had some kind of graph and the text, 'think outside of the box' along the bottom and 'A new TOE?' down the side. The idea of getting a new toe really is outside the box and I wondered which problem it was considered to be a solution for, although at the back of my mind I knew it was probably something like Tons of Oil Equivalent (actually, it was Theory Of Everything.) I wish I'd taken a screenshot.
You people with ad-blockers are missing out on so much.
Admin
Occasionally one does need more than one character for a middle initial. At my last job, there were two employees who had the same exact first, middle, and last names. Supposing that their names were John Andrew Smith and John Andrew Smith, it was common for official reports to refer to them as John A1 Smith and John A2 Smith. (Fortunately the headaches stopped when John A2 Smith got married and got a hyphenated name.)
Of course, 255 still might be a bit excessive.
Admin
Ah, the ole lunatic statement delivered with the absolute certainty that ignorance provides. I have yet to find a suitable reply to statements like that
Admin
In university, we had this project porting a php/html written patient register to Java. The system stored information about patients and a set of forms for each patient. THe guys who wrote the application had never used a database before and there was 4 tables where the biggest one had about 250 attributes! We looked through the schema, and laughed pretty good when we found that "age" was defined as varchar(255). (The guys who wrote it was students and wrote it on their spare time, so mocking it is perhaps against the tdwtf-principles, but I think it's still a quite amusing story..)
Admin
oh hell. stop screwing around and use a sql server 2008 "filestream" field.
you know, although (I think) filestream is a really terrific idea, i start having seizures when i think about how badly this thing is going to be abused.
By the way: FIST!!!!!!!!!111!!##!#1oneone
Admin
I starting my career working for a telecoms systems supplier in their research department. After working late one night the CTO was talking to me about the database we'd started to use, and he said:
"You should be using a flat file system. In all my years working in IT text files are the only thing that have stayed the same".
What can you say to that? Really?
Admin
Admin
stop screwing around and use the new sql server 2008 "filestream" datatype. attach the middle initial as an eps file. or a png. whatever floats your boat.
although i really think that filestream is cool and potentially very useful, i start having seizures when i think about how abused this thing is going to be.
"Why can't I store a PDF as a filestream document and then search the contents in a SELECT statement?"
Admin
Perhaps that database designer ran into someone like my mother, who has two middle names.
Admin
Nvarchar must be a typo
Admin
When I asked my boss about using source control, he said it was a bad idea because developers sometimes work on the same files and version control doesn't handle that well.
(The preferred method (obviously) is having changes overwritten periodically because you're all editing on the same file on the server...)
And yeah, no good response :(
Admin
When a programmer who is not a DBA or even very conversant with databases builds an app that requires one, they usually don't spend a whole lot of time worrying about database design, and they usually won't do anything more complicated than simple SELECT statements to query the data. These people will often set every field in the database as some variant of VARCHAR(255) because they don't really care that much about maximum efficiency on the database side. The only exception is when the programmer aspires to be a DBA (for some unknown reason).
Programmers tend to treat databases as simple data stores from which to obtain data, and then use the language they're programming in to do all the heavy lifting involved in manipulating that data. DBAs, on the other hand, tend to use a lot of stored procedures and whatnot to get the database to do all the heavy lifting. Both groups tend to think their way is superior.
Admin
The only WTF about that database field is that it's called "MiddleInitial" when it should be called "MiddleName".
I have to wonder if perhaps Jerry the flat-file guy is related to Gary the frames guy...
Admin
Flat files are much smarter to use. You can store more data on your drive if you use flat files because they are so thin you can stack them on top of each other.
Admin
I know that "LOL" is a cliche, but this actually made me laugh out loud. Good thing I'm working from home today.
Admin
Admin
Admin
Admin
gang pressed?
Admin
Yup, using a length of 255 for a middle initials field is stupid.
Regards
Alan Q. T. Z. D. I. B. I. W. K. L. S. D. W. Z. Q. R. R. G. O. A. P. Ú. Q. C. Y. S. L. Q. C. F. C. D. R. E. M. W. L. H. X. Í. C. L. Q. C. F. I. W. A. L. S. S. S. S. S. S. É. L. E. E. A. O. D. P. Ú. Q. C. Y. S. L. R. V. M. W. L. D. T. N. Ú. U. R. D. D. A. L. W. C. Brown
Admin
I saw something similar from an Indian programmer once, a numeric range was specificed as 1-1000 or so. We got back a varchar(1000).
Admin
It was a typo to write National Character data type in the first place. It adds nothing to SQL that the default character set and defining a character set per-column doesn't already provide.
Admin
Admin
My ultra thin hard drives is so thin. "how thin is it?" My ultra thin hard drives is so thin it only supports flat files.
Admin
They also go across the intarweb more smoothly, because so many more of them can fit into the tube.
Admin
Fair enough. Realistically, though, I suspect that if our naming conventions ever change to the point where it's even slightly common for people to have more than 255 separate names, or there are over 255 people with the same exact name working in the same place, we will have to overhaul the way we represent and store names anyway.
Admin
whats more stupid is your sig in the comment you posted.
Admin
Are you posing that as a WTF or are you seriously posing that as an acceptable way to solve the problem of two people having the same name?
Admin
Admin
I already wrote this (this WTF must be from the side bar)... but this will be the first field against the wall when UTF-2048 comes.
Admin
Well it is so much better than the way a lot of health insurance companies deal with twins. Either one claim is always denied because they feel you are double claiming, or one child is "born" a month later.
Admin
The Real WTF (tm) is he wanted to use MySQL for it. Yes. MySQL quite easily crashes and corrupts data.
Admin
MS-Access and old versions of MySQL are unstable.
Admin
Don't laugh too hard... how is any different from including XML parsers to pick values out of the xml stored in giant VarChars. And that is the lastest feature in just about every 'serious' Database out there
Admin
I once worked on a database that had a field called "sex". I naively assumed it would be a single character, M or F. When my program failed, I checked again and found that it was two-digit numeric. I briefly wondered if it was not "which" but "how often" or "how good". I eventually discovered that it was really more like "title code". It had started out as 1 for Mr, 2 for Miss, and 3 for Mrs, but over time they gradually added in Doctor, Lieutenant Colonel, Baron (we had European customers), etc, and had to expand it from one digit to two.
My point being, there are probably many fields in systems today whose name accurately describes what they ORIGINALLY contained, but which have been enhanced or junked up (depending on the circumstances and/or your viewpoint) over the years.
Admin
This may seem strange, but that actually happens. Two twins will be born at once and the insurance company will give them different birthdays for the exact reason stated. It's a workaround for the many old legacy mainframe systems that serve as the underpinning of their financial systems.
Admin
TRWTF is that the man got married and changed his name. WTF, grow some balls and keep your name!
Admin
Admin
Of course, the proper way to do this is to use the members' ID numbers for all identifications. The ID numbers used to be SSNs, but after HIPAA they're still 9 digits and unique, but no longer SSNs. They're sometimes referred to as certification numbers.
Admin
not a complete WTF. big commercial DB's like oracle do crash and get corrupted often, and recovery can be a pain. (as a developer who works with banks, DB corruption and recovery is a major issue.) but of course they are necessary in those situations. however, flat-file based DB's like HSQLDB are just fine for small databases, and sometimes preferable since the recovery process can be much easier, especially for a small company with no DB admin. so...he had a point. just sayin.
Admin
Way to suck the fun out of this!
Admin
Thoroughly agreed.
Yours,
Johann Gambolputty de von Ausfern- schplenden- schlitter- crasscrenbon- fried- digger- dingle- dangle- dongle- dungle- burstein- von- knacker- thrasher- apple- banger- horowitz- ticolensic- grander- knotty- spelltinkle- grandlich- grumblemeyer- spelterwasser- kurstlich- himbleeisen- bahnwagen- gutenabend- bitte- ein- nürnburger- bratwustle- gerspurten- mitz- weimache- luber- hundsfut- gumberaber- shönedanker- kalbsfleisch- mittler- aucher von Hautkopft of Ulm
Admin
Yes you would think so. The problem is that in some systems this number is generated from the birth date. The day is not included in this so you have a policy number portion, policy version, month of birth, year of birth. Those get smashed together into an individuals plan member number. Since names don't come into play here, now think about what happens when you have twins. This is why they are "born" a month apart, it takes that much of a difference to get a different number.
Admin
I really should introduce this guy to an ex co-worker who created a database and table to store one single row of configuration parameters for an application he was tasked to develop. This added a $3,000 requirement (SQL Server) to an application that otherwise needed none. A poor copy of cron, or windows scheduled tasks since it ran on windows.
Sometime a text file is better. It's just a matter a chosing the right nail for you hammer.
Admin
That depends on which problem you're referring to. In this case, the name was not being used as a database key or anything; the system was perfectly capable of treating two people with the same name as different entities. If I recall correctly, a unique employee ID number was used for this purpose.
The problem only arose when schedules and other human-readable reports needed to be generated. These guys needed to know which one of them was supposed to work which shift, and so did other people, like the supervisors assigned to those shifts. It was decided that a number would be appended to the middle initials; the guy with more seniority got #1. This organization had a staff of around 250, so the odds that this sort of issue would occur often enough to merit spending more effort on it were judged to be acceptably low.
If you don't consider this an acceptable solution to this problem, please suggest something better.