7 |
The LA Fox Developer Newsletter
April 1999
Hot Tip...
The Neglected NVL() Function
by Barbara Peisch
FoxPro Developers of San Diego
Ever hear of the NVL function? It’s been in VFP since version
3.0, but it’s surprising how few of us know about it. (I hadn’t
heard of it until fairly recently.) Essentially, it says, if the
expression I’m asking for returns a .NULL., substitute some-
thing instead, otherwise, give me what I’m asking for. If you do
outer joins, this can be especially useful. Here’s an example of
how you’d use this function:
Select CustName, NVL(lnvNum,”), NVL(lnvAmt,0)
from Customers;
left outer join Orders on Customers.Custld
=
Orders.Custld;
into cursor OrderHist
In the example above, I want a list of of all invoices and the
amounts, along with the name of the customer who placed the
order. The catch is that if there are any customers who’ve never
placed an order, I still want to see their name. In those cases,
the invoice number and invoice amount would be .NULL., which
can be pretty ugly if you’re displaying this info for an end user.
By using NVLO, I can specify to return an empty string instead
of.NULL. for the invoice number, and 0 instead of .NULL. for the
invoice amount.
Outand About
(Con't from page 6)
parting
of the ways with the team and Dennis Rodman. Granted
the man says he’s misunderstood, blah, blah, blah, but let’s
face it. Anyone that “can’t find his shoes and socks” and, as a
result, shows up late to practice. ..let’s face it, it’s not worth
wasting any more print space on it. Maybe a more accurate
statement would have been that he couldn’t find a pair of shoes
and socks to match his hair.
“e-Cards”
are becoming quite the item, so in an effort to stay
current, here’s a list of some sites
that you can go to:
http://www.toonogram.com
http://www.game-Iand.com/greetings
http:/Mww.cards.eesite.com
http://www.arkworld.com/southpark
http://www.bluemountain.com
and a “links” page at
http://members.tripod.com/demonwolf
If you’re just looking for off-the-wall sites:
http://www.lunaticlounge.com/treklove
http://www.acclaimedimedia.com/voa fa/bnn.htm
http://www. walshnet.com/walshnet/punster/realname.htm
http://www.cyberhighway.net/~transnet/humor/lconsult.htm
From the Humor Dept....
Top 20 Programmer Replies
Contributed by Harry Inge
20.
“That’s Weird...”
19.
“It’s never done that before.”
18.
“It worked yesterday.”
17.
“How is that possible?”
16.
“It must have a hardware problem.”
15.
“What did you type in wrong to get it to crash.
14.
“There is something funky in your data”
13.
“I haven’t touched that module in weeks!”
12.
“You must have the wrong version.”
11.
“It’s just some unlucky coincidence.”
10.
“I can’t test everything!”
9.
“THIS can’t be the source of THAT.”
8.
“It works, but it’s not been tested.”
7.
“Somebody must have changed my code.”
6.
“Did you check for a virus on your system?”
5.
“Even though it doesn’t work, how does it feel?
4.
“You can’t use that version on your system.”
3.
“Why do you want to do it that way?”
2.
“Where were you when the program blew up?”
1.
“I thought I fixed that.”
Job Ops
Needed: Vistal FoxPro 6.0 Programmer (Immediately)
Project: Working with a distribution company
Where: Modesto, CA
Duration: Initially 2 weeks. Lots of work if you work out.
Rate: Negotiable
Needed: Visual FoxPro 6.0 Programmer (Immediately)
Project: Working with a doctor developing his database with
internet
connectivity
Where: Burbank, CA
Duration: As needed. Could turn into sizeable project. Again, if
you work
out
Rate: Negotiable
Contact:
Armando A. Andrade
Solutions Consulting Group, Inc.
A Microsoft Solution Provider Partner focusing on Corporate
Application Development and Data Mart Solutions
6540 Lusk Blvd.
Suite C-200
San Diego, CA. 92121
619-455-7881 Office
619-455-1782 Fax
http://www.scq.net
Page
7
|
7 |