|
|
|
| Non-WTF Job: C++ Developer at Good Grievance (Ronkonkoma, NY) |
| « The FOR-CASE paradigm | XML? » |
Addy Santo sends in a interesting example of portability ...
A friend of mine started a gig as a solutions architect on a classic "project from hell". Since then he has spent 90% of his time cat-herding a clueless team of developers. Among the tidbits he shared with me, this one stood out especially:
StringBuilder f = new StringBuilder();
f.Append(TYPE_OF_LOCATION);
f.Append(PConstants.SPACE);
f.Append(PConstants.EQUALS);
f.Append(PConstants.SPACE);
f.Append(this.HomeLocationCode.ToString());
return f.ToString();The end result being, of course, a dynamic SQL where clause of "TYPE_OF_LOCATION = 1". I guess they were worried that future versions of SQL server wouldn't support " " or "=" characters in queries?
| « The FOR-CASE paradigm | XML? » |