The typical WF output syntax begins with a verb such as PRINT or SUM. After identifying the fields to be output, the syntax provides a way of designating the output file format such as
ON TABLE PCHOLD FORMAT PDF
Looking at the documentation is highly recommended.
HTH
Yes there is a way to add 'dummy' rows: it is called the MacGyver Technique. It will do what you need. Go over to the Information Builders' site and search for it.
Note: you may have to be registered to access this info.
When you say 'MASTER FILE,' are you referring to the synonym or master file description? Or are you talking about extracting data for subsequent use in reports?
If the latter, consider using a multi-verb request. Consider also the use of the TOT. prefix.
I would urge caution regarding...
It has been my preference to let SQL do what it does best, extract data, and let WebFOCUS do what it does best;ie, accumulate, analyze, style, and present data in varios formats.
That being said, I still like having MFDs (Master File Descriptions) available for each table for the quick and irty...
There is a wealth of functions in WebFOCUS that deal with H format date-time data. They are listed in the Functions manual and in another book, (Almost) 1001 Ways to Work With DATES in WebFOCUS.
Having said that, just what do you want to do with the date and I can be more specific.
This is a well-known issue with FOCUS and WebFOCUS. You can address it by defining a blank one-byte field and doing your major sort on it. Then
ON MYBLANKFLD COLUMN-TOTAL AS '
HTH
Yes - that is the info that I was seeking.
When you use EDIT(AGENCY_SALES_V.AGENCY_SALES_V.MTH, '99'),
you are telling WF to get the FIRST two bytes of the field, hence the zeroes in your answer. This being a numeric field, the information is right justified and you would want the last two...
Kerry-
Have you considered a DEFINE?
something like
DEFINE FILE INPUT
SALES2007/P12 = IF YEAR EQ '2007' THEN SALES ELSE 0;
SALES2008/P12 = IF YEAR EQ '2008' THEN SALES ELSE 0;
SALESDIFF/P12 = SALES2008 - SALES2007;
END
TABLE FILE INPUT
SUM
SALES2007 AS '2007,SALES'
SALES2008 AS '2008,SALES'...
Kerry-
What are the Master File Descriptions (MFD) of the fields in question? ie what is the format? Actual and Usage? Length?
This will help us answer your question.
You request shows 20070215 for an I11 field; how is the rest of the field filled?
&YYMD should return integer values 20080212 for today. This is a legacy date format. Is the field in question a standard date? (We once called them smart dates.)
Or is it a date/time stamp?
How about
DEFINE FILE TABLE1
TYPE1/I5 = IF TYP-IND EQ '1' THEN 1 ELSE 0;
TYPE2/I5 = IF TYP-IND EQ '2' THEN 1 ELSE 0;
TYPE3/I5 = IF TYP-IND EQ '3' THEN 1 ELSE 0;
TYPE4/I5 = IF TYP-IND EQ '4' THEN 1 ELSE 0;
END
TABLE FILE TABLE1
SUM TYPE1 TYPE2 TYPE3 TYPE4
BY EFF-DATE AS "WEEK ENDING"
etc
You...
If the numeric is an integer the EDIT(IntField) should work. If number is floating point then FTOA (Float to Alpha) or DTOA (Double to Alpha) should work.
Using the GUI would make this fairly straight-forward but...
The concatenation operator comes in two flavors:
1) | weak concatenation
2) || hard concatenation
The difference is that the hard concatenation will move trailing blanks to the end of the concatenated string but weak concatenation...
&DATEMDYY brings back a date with separators eg mm/dd/yyyy.
DATEDIF is expecting date in format YYMD (or some variation there of), ths so-called standard date or what we once called a 'smart date' so first make sure that both of your date parms are in standard format.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.