February 08, 2008, 04:01 AM
Tony AWarning - usage of characters in Hold file name
Folks,
A little heads up as this has caused more than a little hair loss for me this morning.
I am testing a piece of code that uses MATCH, so in a usual manner I choose a hold file name that will not conflict with anything else - in this instance something with 'xxxx' within it.
APP PREPENDPATH IBISAMP
MATCH FILE GGSALES
SUM DOLLARS
BUDDOLLARS
BY REGION
BY PRODUCT
RUN
FILE GGSALES
SUM UNITS
BUDUNITS
BY REGION
BY PRODUCT
AFTER MATCH HOLD AS Rxxxx_H1 OLD-OR-NEW
END
-RUN
TABLE FILE Rxxxx_H1
PRINT *
END
In essence there is nothing wrong with this code syntactically or logically. But try and run it and you get the error message -
0 NUMBER OF RECORDS SELECTED= 4317 LINES= 39
0 NUMBER OF RECORDS SELECTED= 4317 LINES= 39
0 LINES OF MATCH OUTPUT = 39
0 ERROR AT OR NEAR LINE 14 IN PROCEDURE ADHOCRQ FOCEXEC *
(FOC36219) AN ERROR OCCURED WHEN OPENING FILE: Rxxxx_H1
0 NUMBER OF RECORDS IN TABLE= 0 LINES= 0
Change the 'xxxx' to 'XXXX' and it works OK.
So beware of using lowercase characters in your hold file names.
This is true of the 7.6.2 installation. Interested to know what other versions etc. are affected.
T
February 08, 2008, 04:23 AM
Alan BDitto in 7.6.4
Wonder if this has anything to do with APP HOLD appname being ignored for AFTER MATCH hold files.
Works with an APP FI.
February 08, 2008, 04:28 AM
Tony AForgot to mention the reason behind the open error -
The .mas file gets created but the .ftm doesn't!
Figure that one out!
T
February 08, 2008, 04:35 AM
Alan BYou're right Tony, not created. I thought it was just ignoring the APP HOLD and stuffing it in edatemp.
February 08, 2008, 05:50 PM
LeahI have a feeling this relates to a requirement not to put files in mixed case for the names for consistency across platforms. Which interestingly enoug doesn't apply to mfd references I've found.
February 08, 2008, 06:03 PM
GinnyJakesI tried this on AIX, did an APP HOLD, and I didn't get the master or the ftm file.
February 11, 2008, 02:28 AM
Tony AThanks for the feedback Folks.
At first I thought that it was going to be the old "WF changes filenames, fieldnames etc. to uppercase" but I tried tabling off of RXXXX_H1 with no joy. So I turned temperase off and grabbed the files from edatemp. That's when I found that the .ftm file wasn't even created.
Nice to have a sanity check across versions and platforms though.
Forewarned is forearmed!!
T