You know, in the world of programming, there are things that are nothing short of frustrating. I know that people who don't dig into computer code find it to be something daunting, but once you know one language, they all kind of fall into place, and work almost exactly the same way. It's all about simple logic. When you find situation A, do action B. The trick comes in finding the perfect logic that works every single time, and making sure you know the code you're writing in so that the program reading it understands what the heck you're trying to say.
In this particular instance, I had run up against a very strange error in which a date was being run through a subroutine that changed a blank field into the date 01002000, or January 0, 2000. Well, when a file containing this date went through an import process into another program, it caused the whole process to break down because that's clearly an invalid date, and the importing program knew it.
I know I just gave the whole problem, but finding the date was a needle in a haystack to begin with because that particular record was hidden deep within a file containing many, many other records, most with perfectly valid dates. Once the date was discovered, it was yet more research to figure out where it came from, and I eventually figured out that the system we were pulling the information from had a blank field where a date SHOULD have been.
So now, it came to finding out why something like this would happen. We knew it happened fairly often because this particular client had these import failures on a weekly (and sometimes more often) basis, and after they observed some of claims associated with these dates, they discovered that a date WOULD appear eventually, so we had to basically tell the system to make these records run again if this date came up.
After I found that I couldn't just pass a blank in that field, I decided to just use the date and set the record for pending, but then I had another problem. Once I coded in to set the claim for pending, I had some kind of code error. Now, this system uses a sort of "bastardized" BASIC language, which is the language I grew up on, but this thing was fussing about something invalid about the statement I'd put in there.
I read it and re-read it. I compared it to the rest of the file making sure everything in it was used somewhere else. I checked every character to make sure there was nothing funny about what I'd put in there, but it was all in vain. The stupid thing wouldn't run at all. What made it that much worse was I was controlling someone else's desktop, so they can watch me as I sit idle on this file. I had Optimus take a look. Still nothing.
Then I saw it. Foolishness washed over me. It was so simple that I should have seen it, but it was so easy to overlook. Here's what I wrote:
IF ($PaidDate == "01002000") THEN
SETSTATUS(Claims, PENDED, , , S12345)
//Back out and get the next claim
IF ( 0 == @ReturntoMainMenu() ) THEN
RETURN(0)
ENDIF
RETURN(1)
END IF
Can you see it? The comparison is right there. I'd even cut and pasted the "back out and get the next claim" part from elsewhere in the same file. The solution here is something that anyone with some simple observancy skills should be able to pick up on, and when I reveal the magic answer, if you haven't figured it out yet, you'll kick yourself. It's like a riddle where no knowledge of the subject matter is required for the solution.
Here's the correct version:
IF ($PaidDate == "01002000") THEN
SETSTATUS(Claims, PENDED, , , S12345)
//Back out and get the next claim
IF ( 0 == @ReturntoMainMenu() ) THEN
RETURN(0)
ENDIF
RETURN(1)
ENDIF
See it yet? All right, look at the ENDIF at the end of both of them. The first one has a space between the END and IF, which is correct for regular old BASIC, but remember that someone bastardized this verion, and the BASIC "END IF" is now ENDIF, as in one word, no space.
See? Now wasn't that a fun game? Stare at it for another fifteen minutes before it hits you, and then it's not fun anymore. Still kicking myself.
Friday, October 3, 2008
Wednesday, October 1, 2008
Who's The Boss?
Family dynamics are interesting and remarkably consistent across families, no matter how different they are. I know mine the best, of course, but I've also observed this consistency in other families with a similar makeup. This has to do with birth order.
The first born is the leader and protector of the others. Rock Girl is the one the younger ones always look to, no matter what to find out what they need to do. She is the example and they listen to her (when they want to). In all honesty, they listen to her more than they do us, but she's really good and listens to us, so she does set a good example. When it comes to the protection factor, we've seen her on more than one occasion chastising some poor kid at McDonald's who made her sisters cry. She comes to their rescue unapologetically, for that, we're exceptionally proud of her.
The second child is the quiet one. The Socialite goes with the flow of whatever the others are doing, but she does it with her own style. She very imaginative and creative, but also outgoing. Because she is forced to interact with someone both older and younger than her, she socializes very well. She has already gotten into trouble at school for talking to her friends in class, but this is something we pretty well expected because she takes after the Queen in many, many ways, and this is just one of them. Her downside is that while she can outsmart her sisters, she also allows herself to be pushed around by both of them, which leads us to number three.
The third born is the baby and the boss. Because she's at the bottom of the pecking order, Sassy Pants is the loudest of the three, demands to be heard, and will not rest till her peace is heard, and her way is obtained. While we were driving one day, we heard her demanding to see what The Socialite had because she needed to see it. Now, it wasn't a case of "I want it," but she just needed to look at it. Last night, we asked the Princesses what they wanted for dinner, and the older two declared pizza (well, as you might guess, Rock Girl declared pizza and The Socialite went along with the "awesome" idea), but Sassy Pants went her own way and demanded Mac and Cheese (of all things). Well, having been outvoted, the night was ruined. She whined, complained, and carried on the rest of the evening about wanting nothing other than Mac and Cheese (despite our repeated commentary about home not being a restaurant). As you might also be able to guess, she refused to eat anything.
As luck would have it, they were going to have a pizza day at preschool today. She wanted peanut butter and jelly. Yeah, she got the sandwich in her lunch box.
The first born is the leader and protector of the others. Rock Girl is the one the younger ones always look to, no matter what to find out what they need to do. She is the example and they listen to her (when they want to). In all honesty, they listen to her more than they do us, but she's really good and listens to us, so she does set a good example. When it comes to the protection factor, we've seen her on more than one occasion chastising some poor kid at McDonald's who made her sisters cry. She comes to their rescue unapologetically, for that, we're exceptionally proud of her.
The second child is the quiet one. The Socialite goes with the flow of whatever the others are doing, but she does it with her own style. She very imaginative and creative, but also outgoing. Because she is forced to interact with someone both older and younger than her, she socializes very well. She has already gotten into trouble at school for talking to her friends in class, but this is something we pretty well expected because she takes after the Queen in many, many ways, and this is just one of them. Her downside is that while she can outsmart her sisters, she also allows herself to be pushed around by both of them, which leads us to number three.
The third born is the baby and the boss. Because she's at the bottom of the pecking order, Sassy Pants is the loudest of the three, demands to be heard, and will not rest till her peace is heard, and her way is obtained. While we were driving one day, we heard her demanding to see what The Socialite had because she needed to see it. Now, it wasn't a case of "I want it," but she just needed to look at it. Last night, we asked the Princesses what they wanted for dinner, and the older two declared pizza (well, as you might guess, Rock Girl declared pizza and The Socialite went along with the "awesome" idea), but Sassy Pants went her own way and demanded Mac and Cheese (of all things). Well, having been outvoted, the night was ruined. She whined, complained, and carried on the rest of the evening about wanting nothing other than Mac and Cheese (despite our repeated commentary about home not being a restaurant). As you might also be able to guess, she refused to eat anything.
As luck would have it, they were going to have a pizza day at preschool today. She wanted peanut butter and jelly. Yeah, she got the sandwich in her lunch box.
Tuesday, September 30, 2008
Pillow Sheets
Kids are cute, you know? Through their curiosity and imagination, we see the innocence that makes them so endearing and even appealing, and along these same lines, their creativity to describe their world has always been a source of fascination, at least to me.
Part of this is their mispronunciations. When Rock Girl was learning to speak, we got a kick out of her words such as chlocate, pliggit (as in the Pooh character, Piglet), aminal, and celluwar. The Socialite still requires some interpretation when she asks for a "cheese girl." Any guesses? That would be a grilled cheese sandwich, which she orders only when she can't get a quesadilla (a word she can pronounce perfectly). Sometimes, we wonder about their regional dialect as they all started out talking like people from the east coast (a concept difficult to convey in writing).
What I had to share, though, was the most fascinating so far that was spouted out last night, and that I am not inclined to correct, really, because I find it to be a unique term and something not undescriptive of the object they were going for. You see, the Socialite needed a pillow case. Now, the princesses go through pillow cases like nobody's business because they use them as sleeping bags (yes, sleeping bags), bags to carry toys in, and store stuff in them.
Well, last night, The Socialite declared that she needed a pillow sheet. It only took a moment to figure out what she was referring to, and I got her what she needed. I'd never, ever heard them referred to by that term before, but in a way, it does fit, especially from a child's mind, who doesn't know the actual term. You put a sheet over your bed, and the same material is used to put over your pillow; hence, pillow sheet.
As a short follow up, Sassy Pants has a "pillow sheet" that features the Disney princesses -- one side with only Cinderella, and the other with Cinderella, Belle, and Aurora. Well, when she goes to bed, the side with the three princesses MUST be facing up and it MUST be right side up. No other way is acceptable.
Part of this is their mispronunciations. When Rock Girl was learning to speak, we got a kick out of her words such as chlocate, pliggit (as in the Pooh character, Piglet), aminal, and celluwar. The Socialite still requires some interpretation when she asks for a "cheese girl." Any guesses? That would be a grilled cheese sandwich, which she orders only when she can't get a quesadilla (a word she can pronounce perfectly). Sometimes, we wonder about their regional dialect as they all started out talking like people from the east coast (a concept difficult to convey in writing).
What I had to share, though, was the most fascinating so far that was spouted out last night, and that I am not inclined to correct, really, because I find it to be a unique term and something not undescriptive of the object they were going for. You see, the Socialite needed a pillow case. Now, the princesses go through pillow cases like nobody's business because they use them as sleeping bags (yes, sleeping bags), bags to carry toys in, and store stuff in them.
Well, last night, The Socialite declared that she needed a pillow sheet. It only took a moment to figure out what she was referring to, and I got her what she needed. I'd never, ever heard them referred to by that term before, but in a way, it does fit, especially from a child's mind, who doesn't know the actual term. You put a sheet over your bed, and the same material is used to put over your pillow; hence, pillow sheet.
As a short follow up, Sassy Pants has a "pillow sheet" that features the Disney princesses -- one side with only Cinderella, and the other with Cinderella, Belle, and Aurora. Well, when she goes to bed, the side with the three princesses MUST be facing up and it MUST be right side up. No other way is acceptable.
Monday, September 29, 2008
Happy Meal Toys
I've discovered a wonderous thing in recent months. You ever go to McDonald's, order one of the value meals, and find yourself choking down the last of the fries because there were just too many of them? Maybe you just threw them out. Maybe you tried to take them home and eat them later. Or maybe you just chow right through them, which is also okay.
Me? I find that most of those meals contain entirely too much food, fully explaining the reason we're all getting rounder (and that's not even super-sizing). I'll admit that there are times I'm hungry enough to get a huge meal, but on a normal day, I'd rather not.
Then, they started having Transformers toys in the Happy Meals to promote the new Animated Series, so I figured I'd get those double cheeseburger Mighty Kids Meals, so I could get the toys. Sometimes, I got just the meal, and sometimes I'd pay the extra $1 and get a second double cheeseburger, but I started then, and I've been getting them ever since.
Well, the reason I've continued is because they went from Transformers toys to Star Wars toys, and being the fan I am, I had to see about getting all those bobble heads. In the end, I only ended up with nine of them. The Princesses actually have two that I don't, but I'm not going to sntach them up. I got some and Optimus brought some in, too.
Well, then they went from Star Wars to having Lego Batman toys to promote the Lego Batman game (which I've rave about, I'm sure). Well, I got the first toy, and discovered to my delight, that each toy contained a code for the game to unlock something. Then, I further found out that even the same toys contained different codes. Well, I was hooked. I now have a full set, and Optimus Prime, who is just a Batman fan in general (don't get him started on Dark Knight; he loves it), has been helping in getting the whole set and getting codes.
So at this point, having discovered a decent amount of food in a double cheeseburger and small fries, I've decided to stick with it once they go to Barbie and Hot Wheels, which is next. A double Quarter Pounder is good, but add in the fries, and you've got a huge meal. Yes, I can eat it, but I also want to live long enough to see some great grandchildren, so I'm cutting back.
Besides, how can you go wrong with a collection like this (note the full set of Batman toys...):
Me? I find that most of those meals contain entirely too much food, fully explaining the reason we're all getting rounder (and that's not even super-sizing). I'll admit that there are times I'm hungry enough to get a huge meal, but on a normal day, I'd rather not.
Then, they started having Transformers toys in the Happy Meals to promote the new Animated Series, so I figured I'd get those double cheeseburger Mighty Kids Meals, so I could get the toys. Sometimes, I got just the meal, and sometimes I'd pay the extra $1 and get a second double cheeseburger, but I started then, and I've been getting them ever since.
Well, the reason I've continued is because they went from Transformers toys to Star Wars toys, and being the fan I am, I had to see about getting all those bobble heads. In the end, I only ended up with nine of them. The Princesses actually have two that I don't, but I'm not going to sntach them up. I got some and Optimus brought some in, too.
Well, then they went from Star Wars to having Lego Batman toys to promote the Lego Batman game (which I've rave about, I'm sure). Well, I got the first toy, and discovered to my delight, that each toy contained a code for the game to unlock something. Then, I further found out that even the same toys contained different codes. Well, I was hooked. I now have a full set, and Optimus Prime, who is just a Batman fan in general (don't get him started on Dark Knight; he loves it), has been helping in getting the whole set and getting codes.
So at this point, having discovered a decent amount of food in a double cheeseburger and small fries, I've decided to stick with it once they go to Barbie and Hot Wheels, which is next. A double Quarter Pounder is good, but add in the fries, and you've got a huge meal. Yes, I can eat it, but I also want to live long enough to see some great grandchildren, so I'm cutting back.
Besides, how can you go wrong with a collection like this (note the full set of Batman toys...):

Subscribe to:
Posts (Atom)