This is a followup of sorts to this one: "My Recurring Nightmare" (15 Oct 2016).
On Friday, for our project 2 team in CS411: Database Systems, I needed to demonstrate the software we're developing to the professor via Skype. The project is to develop a program that can perform SQL queries on CSV files. On Thursday night, I had a version of the code that only had simple capabilities (a single WHERE statement on a single table), but it worked.
And what follows is where we get the saying: leave well enough alone.
Since I ended up taking a sick day from work on Friday, I spend some of the time trying to develop more capabilities in the code. Mainly, just trying to get the thing to accept multiple WHERE statements. Naturally, I broke something. And that something that I broke, well, it broke everything. At least before it gave some correct outputs for simple inputs. But after the "improvement": blank answers for everything.
And that's what I got to present to the professor. Laugh or cry—what difference does it make?
At least I got to walk him through the code and explain how it was working the evening before. And it didn't turn out too bad because the other project teams were also having problems, so another intermediate demo was scheduled. And I was able to get in there and, first, fix the thing I broke, and second, add the extra capability I was trying to get in there in the first place. So all's well that ends well.
That moment of terror an hour before presentation time, though, was the stuff of occasionally recurring nightmares about college. I was tempted to say I learned my lesson about fussing with things that are good enough, but I've lived in this head long enough to know that I'll do it again, and at the first available opportunity.
On GitHub, if you can work Python and would like to give it a try: SQL CSV ASAP.