Yesterday, with some detailed help of a friend of a friend, I finished writing my very first (of three) PHP scripts that will put actual data into the database! (Up to that point it was lots of short scripts to put ancillary info into it, such as home institutions of cruise crews, funding agencies, the serial numbers and calibration dates of every sensor we've ever used to measure anything, etc.). Yay! I'm totally awesome!
Then I started work on the second script. Right away I noticed two things: PHP isn't going to like reading this dataset, and the haphazard way I was processing the data before has just come back to haunt me. It's going to be an organizational nightmare that will take ten times more code to accommodate than if I'd known what I was doing in the first place. Augh! I hate myself and want to die!
The friend of a friend comes to the rescue again and talks me past the problems. Yay! There was much rejoicing and happy-dancing!
I code and code and code some more. It suddenly occurs to me that I've been doing it wrong the whole time. The better way would not have required me to learn quite as much PHP as I just did. Augh! I'm a total idiot!
But I'm in luck, because most of what I just coded for PHP from the command line is still going to be the same from the web browser. I just need to ... code even more. Some surrounding bits, plus the scripts that will make all the pretty buttons. But I know how to do HTML forms because that's what all of those short scripts from before are. Yay! I'm totally awesome! The second script is almost finished!
I wonder what tomorrow will bring when I debug the second script and then start working on the third script. Special thanks go to my new best buddy Randi Mitchell, for being willing to sit around handholding a total stranger through some excruciatingly detailed material. :)
31 October 2007
Subscribe to: Post Comments (Atom)
Congrats! My coding has been limited to an absurdly long BASH script for manipulating a huge flat text database at the school. It's mainly nested AWK and SED statements in complicated loops. It's really bad, but does the trick.
I wish I knew perl, that would have made life easier. Heck, I wish I knew PHP, because then it could even be pretty. :)
I tried to learn perl once but it was too arcane. PHP was too, but someone got me started, and now I have people to ask (though some of them think I should be using java instead - which I also don't know). I actually don't know much at all about awk or sed, so you're ahead of me there. ;)
Post a Comment