new RPG


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]

Posted by Carl Haaser on December 27, 2010 at 12:57:06:

I am using the PROMPT command to get the month %Billmo%. The following command works: SELECTING IF BAR%Billmo% NE 0 but it doesn't convert the month later in this statement: DEFINE LAST.YR.TOT=BAR%Billmo% ;7.0;LAST.YR.TOT

I know it's redundant and I should just print the field instead of using a define but there are 3 reports linked and the last is a total of fields BIL%Billmo% and BAR%Billmo%.

Here are the results for the report:
PRINTER LPH
INPUT CUST.LBS.HIST
cust.lbs.hist VSC1LB -
TITLE "CUSTOMER BAR LBS. SALES COMPARISON REPORT-05/31/10"
TITLE "*** BARCOMP ***"
REPORT
SELECTING IF BAR01 NE 0
SELECTING IF BAR05 NE 0 !This is BAR%Billmo%
SELECTING IF BIL01 NE 0
SELECTING IF BIL05 NE 0 !This is BIL%Billmo%
USING LBS.HIST.2.CUST
DEFINE THIS.YTD=_
BAR01;7.0;THIS.YTD
DEFINE LAST.YTD=_
BAR13;7.0;LAST.YTD
DEFINE LAST.YR.TOT=BAR%Billmo% ;7.0;LAST.YR.TOT !This should be BAR05
DEFINE PREV.YEAR=_
BAR16;7.0;PREV.YEAR
PRINT CUST.NO;NAME;THIS.YTD;LAST.YTD;LAST.YR.TOT
ERROR = 16 - bar Field Name not found

FATAL Errors exist. Cannot process Report:




Follow Ups:



Post a Followup

Name:
E-Mail:

Subject:

What is the name of the main Signature System's Product?  

Comments:

Optional Link URL:
Link Title:
Optional Image URL:

You may attach up to 5 files to your followup (see below):





Each file can be a maximum of 1MB in length Uploaded files will be purged from the server on a regular basis.


[ Follow Ups ] [ Post Followup ] [ Signature.net Forum ]