calculated field using record num in report problem with 4.5 dos

calculated field using record num in report problem with 4.5 dos

Post by rob » Fri, 04 Jul 2003 00:55:01



I need to create a calculated field in a report that maps record 1 to 120, 2
to 130, 4 to 140 and so on.  When I try use the record number [#], Paradox
will not accept it and gives me an error message.  The calc'd field should
have looked like this "10*[#]+110" to perform as wished.  It is just the
reference to the record number that is hosing me up.  Any ideas?
 
 
 

calculated field using record num in report problem with 4.5 dos

Post by Mike Irwin [CTech » Fri, 04 Jul 2003 01:15:46


Here's an example of how. Adapt it to your own circumstances as
appropriate:

1. Create a new report
2. Add a TableFrame object to the AllRecords band
3. Right-click the TableFrame and select Define Table
4. Select a table and bind two fields
5. Select the left-most column (click in the third row until the
column selects) and insert a new column - it will now be the new
left-most column
6. Define the field; drop the field list and select "Record
Number".
7. Repeat step 5
8. Define this new field as a calculated field with the formula

( 10 * Record_Number ) + 110

Run report

QED.

You can, of course, arrange things so that the Record Number
field is not visible, and you can drag that field into another
column and dispense with the column entirely !

hth

Mike



Quote:> I need to create a calculated field in a report that maps record 1 to 120, 2
> to 130, 4 to 140 and so on.  When I try use the record number [#], Paradox
> will not accept it and gives me an error message.  The calc'd field should
> have looked like this "10*[#]+110" to perform as wished.  It is just the
> reference to the record number that is hosing me up.  Any ideas?


 
 
 

calculated field using record num in report problem with 4.5 dos

Post by Kevin Donaker-Rin » Fri, 04 Jul 2003 08:01:36


Mike,

Those don't like like PdoxDOS instructions to me.

--
Kevin
(if you email me, make sure to DeSpamulate my address)
------------------------------
-     Kevin Donaker-Ring     -
-  Executive Director, AISE  -
-    http://www.aise.com     -
------------------------------


> Here's an example of how. Adapt it to your own circumstances as
> appropriate:

> 1. Create a new report
> 2. Add a TableFrame object to the AllRecords band
> 3. Right-click the TableFrame and select Define Table
> 4. Select a table and bind two fields
> 5. Select the left-most column (click in the third row until the
> column selects) and insert a new column - it will now be the new
> left-most column
> 6. Define the field; drop the field list and select "Record
> Number".
> 7. Repeat step 5
> 8. Define this new field as a calculated field with the formula

> ( 10 * Record_Number ) + 110

> Run report

> QED.

> You can, of course, arrange things so that the Record Number
> field is not visible, and you can drag that field into another
> column and dispense with the column entirely !

> hth

> Mike



>>I need to create a calculated field in a report that maps record 1 to 120, 2
>>to 130, 4 to 140 and so on.  When I try use the record number [#], Paradox
>>will not accept it and gives me an error message.  The calc'd field should
>>have looked like this "10*[#]+110" to perform as wished.  It is just the
>>reference to the record number that is hosing me up.  Any ideas?

 
 
 

calculated field using record num in report problem with 4.5 dos

Post by Steven Gree » Fri, 04 Jul 2003 08:19:44



> Those don't like like PdoxDOS instructions to me.

I didn't notice that it said DOS either..

--

Steve Green - Diamond Software Group, Inc - Waldorf Maryland USA
Corel CTech Paradox - http://www.diamondsg.com - Support/Downloads/Links
---------------------------------------------------------------------------------
Do you need a Sanity Check? http://www.diamondsg.com/sanity.htm
Upgrade/Downgrade versions? http://www.diamondsg.com/upgrade.htm
-------------------------------------------------------------------------

 
 
 

calculated field using record num in report problem with 4.5 dos

Post by Steven Gree » Fri, 04 Jul 2003 08:20:53



> I need to create a calculated field in a report that maps record 1 to 120, 2
> to 130, 4 to 140 and so on.  When I try use the record number [#], Paradox
> will not accept it and gives me an error message.

in a PdoxDOS report, you can't do it that way.. if you *must* use Recno() in a
calc, you'll need to create an extra field, SCAN the table to seed it with
RECNO(), then use that field in your calcs..

--

Steve Green - Diamond Software Group, Inc - Waldorf Maryland USA
Corel CTech Paradox - http://www.diamondsg.com - Support/Downloads/Links
---------------------------------------------------------------------------------

Do you need a Sanity Check? http://www.diamondsg.com/sanity.htm
Upgrade/Downgrade versions? http://www.diamondsg.com/upgrade.htm
-------------------------------------------------------------------------

 
 
 

calculated field using record num in report problem with 4.5 dos

Post by Mike Irwin [CTech » Fri, 04 Jul 2003 23:20:04


They're not ... I didn't read the last word in the title because
it truncated. Sorry. However, maybe Steve can tell you if the
same principle holds true ...

Mike



Quote:> Mike,

> Those don't like like PdoxDOS instructions to me.

 
 
 

calculated field using record num in report problem with 4.5 dos

Post by rob » Wed, 09 Jul 2003 12:05:48


Thanks, I shall give that a try.



> > I need to create a calculated field in a report that maps record 1 to
120, 2
> > to 130, 4 to 140 and so on.  When I try use the record number [#],
Paradox
> > will not accept it and gives me an error message.

> in a PdoxDOS report, you can't do it that way.. if you *must* use Recno()
in a
> calc, you'll need to create an extra field, SCAN the table to seed it with
> RECNO(), then use that field in your calcs..

> --

> Steve Green - Diamond Software Group, Inc - Waldorf Maryland USA
> Corel CTech Paradox - http://www.diamondsg.com - Support/Downloads/Links
> --------------------------------------------------------------------------
-------

> Do you need a Sanity Check? http://www.diamondsg.com/sanity.htm
> Upgrade/Downgrade versions? http://www.diamondsg.com/upgrade.htm
> -------------------------------------------------------------------------

 
 
 

1. Calculated field in form, Paradox 4.5 dos

I can't make sense why a calculated field as simple as:

[Sacchi]*IIF([Descrizione]="coccio",50,30)

should smoothly work on my computer but doesn't on a 386 with 8mb. [Sacchi] is
a numeric field, while [Descrizione] is alphanumeric; they are both already
present on the form, which is multirecord. It does its job on my computer but
when I transfer it on this 386, where the Paradox version in exactly the same,
it crashes with a MakeExprTree error, giving the hint it might be due to a
damaged form. If I try to type in the calculated field directly on that
computer, it gives a syntax error on the above formula. Any idea ?

2. Inserting data using beans through JDBC

3. Calculated Field Problem. Delphi w/ Pdox 4.5 Table

4. Problem with replication

5. PDX 4.5 for Dos Sum Field on Page Problem

6. Linked Server to Oracle

7. DOS 4.5 Runtime used in Win95 - Problem??

8. tablespace datafiles only filled up to 50%

9. Dos4.5-Report/calculated field using lookup table field

10. Report in dos 4.5

11. Crystal Reports and Pdox 4.5 Dos

12. Reports for Paradox 4.5 Dos