Is This a Bug?
Bob Stockler
bob at trebor.iglou.com
Thu Sep 9 16:02:37 PDT 2004
On Thu, Sep 09, 2004 at 06:47:00PM -0400, John Hemmer wrote:
|
| ----- Original Message -----
| From: "Bob Stockler" <bob at trebor.iglou.com>
| To: "filePro mailing list" <filepro-list at lists.celestial.com>
| Sent: Thursday, September 09, 2004 5:44 PM
| Subject: Re: Is This a Bug?
|
|
| > On Thu, Sep 09, 2004 at 02:58:24PM -0400, John Hemmer wrote:
| > | The following code:
| > |
| > | Then: A(3,.0)="25"
| > | Then: B(3,.0)=MAX( "1", A-"8" )
| > | Then: C(3,.0)=A-"8"
| > | Then: D(3,.0)=MAX("1",C)
| > | Then: SHOW "A="{A<"B="{B<"C="{C<"D="{D
| > |
| > | Gives the following result:
| > |
| > | A=25 B=1 C=17 D=17
| > |
| > | If I enclose A-"8" in parenthesis such as:
| > |
| > | Then: B(3,.0)=MAX( "1", (A-"8") )
| > |
| > | I get the same result. I would think that I should get
| > | a value of 17 for B.
| > |
| > | I am compiling with rcabe version 5.0.13.R4
| > |
| > | I get the same result using both rclerk and dclerk.
| >
| > Well, it's consistent anyway.
| >
| > I don't think filePro is going to do arithmetic/math for you
| > within arguments to the MAX() function.
| >
| > Bug or design decision, I don't know.
| >
| > For now, anyway, it seems you'll have to do your arithmetic/math
| > to a variable befor you use the MAX() function,
| >
| Maybe I should have included the example where it does the math
| correctly within MIN(). The following code:
|
| Then: A(3,.0)="25"
| Then: B(3,.0)=MIN( "79", A+"8" )
| Then: C(3,.0)=A+"8"
| Then: D(3,.0)=MIN("79",C)
| Then: SHOW "A="{A<"B="{B<"C="{C<"D="{D
|
| Gives the following result:
|
| A=25 B=33 C=33 D=33
|
| It demonstrate that it doing math within () works for MIN.
|
| Perhaps filePro has a bug parsing the hypen treating it like an
| argument-separator instead of a minus-sign, but I would have
| thought nesting the math in parenthesis such as with ......
|
| B(3,.0)=MAX( "1", (A-"8") ), would correct that.
Maybe you should have.
Maybe you have a point there.
Bob
--
Bob Stockler - bob at trebor.iglou.com
Author: MENU EDIT II - The BEST Creator/Editor/Manager for filePro User Menus.
Fully functional (time-limited) demos available by email request (specify OS).
More information about the Filepro-list
mailing list