Focal Point
[SOLVED] Master-described DATE in csv file

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/4291019892

September 10, 2008, 01:22 PM
Foccrawler
[SOLVED] Master-described DATE in csv file
Hi all,
I have a question specifically related to a csv file and its master (.mas) describing a date field.

With this next paragraph I am going to try to pre-empt all the many questions that will no doubt arise. First when looking at the actual data whether in Excel or a text editor it will appear in the format 8/30/2008. The master file description for the field follows:
FIELD=PAY_END_DT, ALIAS=FIELD2, USAGE=MDYY, ACTUAL=DATE, $
Next, the Master does include the syntax of (in the first line):
SUFFIX=COM,
....and the .fex that is TABLE'ing this file carries the syntax:
SET PCOMMA=ON
An appropriate FILEDEF has been established.

Here is the clincher: In WF 5.3.2 the exact same thing works. In 7.6.4 it doesn't. The resulting error message for each line of data is:
(FOC209) THE DATA VALUE EXCEEDS ITS LENGTH SPECIFICATION: 8/30/2008
...and of course it is therefore repeated a zillion times.

I can only imagine that 7.6.4 is not getting the message that this is a date, in spite of the master and/or it is insisting that the date NOT be supplied in the data file with slashes.

Since 5.3.2 can figure it out though I've been retracing steps a hundred times with no success. Has anyone been this way before?

Bill

This message has been edited. Last edited by: Kerry,
September 10, 2008, 02:31 PM
Prarie
Bill,

First understand there is a world of difference between the Versions you are upgrading. You are going into a much better world. But you will find strange things...that used to work..that actually should not have...but now WebFocus notices it. There will probably be more to come. I think it has something to do with your ACTUAL in the Master. I would try changing that.


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
Right on Prarie....Thank You!

I played with this a little further; changed the ACTUAL to A10 and it works. If I then TABLE and HOLD FORMAT ALPHA the resulting Master then reads A08. Must be the USEAGE of MDYY makes the 2 slashes to be implicit. The .ftm file displays 08/30/2008, just what we want. Thanks again for the correct steer.
Bill
Glad to help.
quote:
FIELD=PAY_END_DT, ALIAS=FIELD2, USAGE=MDYY, ACTUAL=DATE, $



I think I would describe this as

FIELD=PAY_END_DT, ALIAS=FIELD2, USAGE=A8MDYY, ACTUAL=A10, $


Now it becomes a legacy date and you can use it in defines, convert it to a smartdate and make calculations like you can in excel.




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7