As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.
Join the TIBCO Community TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.
From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
Request access to the private WebFOCUS User Group (login required) to network with fellow members.
Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.
I am trying to convert a program that works fine in MRE to be run in ReportCaster. I have started to debug the program and it is a little tedious to say the least. Any help on the following error I have encountered?
TABLE FILE FCT_IndexWeek PRINT COMPUTE INDXVAL/D10.1 = INDEXVALUE * 100; WHERE (YEAR EQ 2007) AND (WEEKNUMBER EQ 45); ON TABLE SAVE AS INDXSAV END -RUN UNRECOGNIZED COMMAND ALPHANUMERIC RECORD NAMED INDXSAV FIELDNAME ALIAS FORMAT LENGTH INDEXVALUE IndexValue P10.5 10 INDXVAL D10.1 10 TOTAL 20 -READ INDXSAV &X.A10 &SEAFAC.A10 -RUN
Task error: UNRECOGNIZED COMMAND No report to distribute.
OK, so you're getting an UNRECOGNISED COMAAND error and you've shown us the output. Unfortunately the output doesn't reflect what the actual code is so place -SET &ECHO = ON; at the top of your code and then post the part of the output that gives the error.
Within MRE there are often pieces of code that are included particularly for MRE (depending upon how the code was produced - editor, report painter etc.) so the preceding code might have a reflection upon it running in RC. Also, rather than wait for it to run from RC just place it in an app folder and run it from there before your final test from RC.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
The fact that you get both the error message and the notification of the hold file being written, strengthens the previous comment, namely that there must be something BEFORE the code shown taht results in the error message. The code you put in here is apparently correct, since it results in a saved file.
GamP
- Using AS 8.2.01 on Windows 10 - IE11.
in Focus since 1988
Posts: 1961 | Location: Netherlands | Registered: September 25, 2007
Sorry, Tried to put in too much output and wouldn't fit. Here is the tables logic right before the unrecognized command and also following the error.
BTP1020 -* GET TOTAL STORES BTP1020 TABLE FILE STORTOT1 BTP1020 SUM MKALLSTR MKSTRCOMP BTP1020 COMPUTE MARKETNAME/A50V = All ; BTP1020 BY OWNER BTP1020 ON TABLE SET ASNAMES ON BTP1020 ON TABLE HOLD AS STORTOTA BTP1020 -* ON TABLE PCHOLD FORMAT HTML BTP1020 END BTP1020 -RUN BTP1020 DEFINE FILE STORTOTA BTP1020 MARKETNAME = Amkt ; BTP1020 OWNER = AHd ; BTP1020 END BTP1020 TABLE FILE STORTOTA BTP1020 SUM MKALLSTR MKSTRCOMP BTP1020 BY MARKETNAME BY OWNER BTP1020 ON TABLE HOLD AS STORTOTB BTP1020 -* ON TABLE PCHOLD FORMAT HTML BTP1020 END BTP1020 DEFINE FILE STORTOTA BTP1020 OWNER = IF OWNER EQ Company THEN ACompany ELSE AFranchise ; BTP1020 END BTP1020 -*------------------------------------------------------------------------------------------------------ BTP1020 TABLE FILE STORTOTA BTP1020 SUM MKALLSTR MKSTRCOMP BTP1020 BY MARKETNAME BY OWNER BTP1020 -* ON TABLE PCHOLD FORMAT HTML BTP1020 ON TABLE HOLD AS STORTOT BTP1020 MORE BTP1020 FILE STORTOTB BTP1020 MORE BTP1020 FILE STORTOT1 BTP1020 END BTP1020 -RUN BTP1020 TABLE FILE SMX_CURRENTSTOREVIEW BTP1020 -* SUM BTP1020 SUM COMPFLAG BTP1020 AllSTR AS MKTALLSTR BTP1020 MKTSTRCOMP BTP1020 BY MARKETNAME BTP1020 BY OWN2 AS OWNER BTP1020 WHERE SALESYEAR EQ 2007 BTP1020 AND WEEKNUMBER EQ 45 BTP1020 ON TABLE SET ASNAMES ON BTP1020 -*ON TABLE PCHOLD FORMAT HTML BTP1020 ON TABLE HOLD AS STORAll BTP1020 END BTP1020 -RUN BTP1020 -*------------------------------------------------------------------------------------------------------ BTP1020 -*------------------------------------------------------------------------------------------------------ BTP1020 -*------------------------------------------------------------------------------------------------------ BTP1020 -FSKIP BTP1020 MATCH FILE STORTOT BTP1020 SUM BTP1020 MKALLSTR BTP1020 MKSTRCOMP BTP1020 BY MARKETNAME BTP1020 BY OWNER BTP1020 AFTER MATCH HOLD OLD-OR-NEW BTP1020 RUN BTP1020 FILE STORAll BTP1020 PRINT MKTALLSTR BTP1020 MKTSTRCOMP BTP1020 BY MARKETNAME BTP1020 BY OWNER BTP1020 AFTER MATCH HOLD OLD-OR-NEW BTP1020 RUN BTP1020 FILE RPTCOL BTP1020 PRINT * BTP1020 BY MARKETNAME BTP1020 BY OWNER BTP1020 AFTER MATCH HOLD AS STORLST OLD-OR-NEW BTP1020 END BTP1020 ========================================================================================= BTP1020 -* GET THE SEASONALITY FACTOR BTP1020 -SET &SELYEAR=2007; BTP1020 -SET &SELWEEK=45; BTP1020 TABLE FILE FCT_IndexWeek BTP1020 PRINT COMPUTE INDXVAL/D10.1 = INDEXVALUE * 100; BTP1020 WHERE (YEAR EQ 2007) AND (WEEKNUMBER EQ 45); BTP1020 ON TABLE SAVE AS INDXSAV BTP1020 END BTP1020 -RUN BTP1020 UNRECOGNIZED COMMAND BTP1020 ALPHANUMERIC RECORD NAMED INDXSAV BTP1020 0 FIELDNAME ALIAS FORMAT LENGTH BTP1020 INDEXVALUE IndexValue P10.5 10 BTP1020 INDXVAL D10.1 10 BTP1020 TOTAL 20 BTP1020 -READ INDXSAV &X.A10 &SEAFAC.A10 BTP1020 -RUN BTP1020 -*TABLE FILE FCT_IndexWeek BTP1020 -* PRINT COMPUTE INDXVAL/F6.1 = INDEXVALUE * 100; BTP1020 -* WHERE (YEAR EQ &selyear) AND (WEEKNUMBER EQ &selweek); BTP1020 -* ON TABLE SET HOLDLIST PRINTONLY BTP1020 -* ON TABLE SAVE AS INDXSAV BTP1020 -*END BTP1020 -*-RUN BTP1020 -* BTP1020 -*-READ INDXSAV &SEAFAC.A6. BTP1020 -*-RUN BTP1020 -* -SET &C = &SEAFAC; BTP1020 -* 11122007 BTP1020 -* -TYPE &SEAFAC BTP1020 -*====================================================================================================== BTP1020 -* GET THE Venues BTP1020 -* SET MESSAGE = ON BTP1020 DEFINE FILE SMX_VENUE BTP1020 CNTVEN/I6 WITH VENUETYPE = 1; BTP1020 VENNAM/A15 = IF (VENUETYPE EQ 2) THEN Venues ELSE BTP1020 IF (VENUETYPE EQ 1) THEN Take N Bake ELSE ; BTP1020 END BTP1020 TABLE FILE SMX_VENUE BTP1020 SUM BTP1020 CNTVEN AS TOTVEN BTP1020 SUM BTP1020 VENNAM BTP1020 CNTVEN BTP1020 BY VENUETYPE NOPRINT BTP1020 WHERE ACTIVE NE 0 BTP1020 ON TABLE SET HOLDLIST PRINTONLY BTP1020 ON TABLE SAVE AS VEN BTP1020 -* ON TABLE PCHOLD FORMAT HTML BTP1020 END BTP1020 -RUN BTP1020 ALPHANUMERIC RECORD NAMED VEN BTP1020 0 FIELDNAME ALIAS FORMAT LENGTH BTP1020 CNTVEN I6 6 BTP1020 VENNAM A15 15 BTP1020 CNTVEN I6 6 BTP1020 TOTAL 27 BTP1020 -SET &CNT = 0; BTP1020 -REPEAT LPVEN 2 TIMES BTP1020 -SET &CNT = 0 + 1; BTP1020 -READ VEN &TOTVEN1.I6. &VENNAM1.A15. &CNTVEN1.I6. BTP1020 -TYPE 41 Take N Bake 29 BTP1020 41 Take N Bake 29 BTP1020 -REPEAT LPVEN 2 TIMES BTP1020 -SET &CNT = 1 + 1; BTP1020 -READ VEN &TOTVEN2.I6. &VENNAM2.A15. &CNTVEN2.I6. BTP1020 -TYPE 41 Venues 12 BTP1020 41 Venues 12 BTP1020 -LPVEN BTP1020 -*====================================================================================================== BTP1020 -*====================================================================================================== BTP1020 -SET &QOT = ; BTP1020 DEFINE FILE STORLST BTP1020 WINDX/D6.1 = 99.4/10; BTP1020 HDRMTH/Mtr = 11; BTP1020 SELIT/I2 = IF (OWNER CONTAINS Company ) THEN 0 BTP1020 ELSE IF (OWNER CONTAINS Franchise ) THEN 1 BTP1020 ELSE 3; BTP1020 CNNC/I6 = 1; BTP1020 END BTP1020 TABLE FILE STORLST BTP1020 SUM BTP1020 CNT.SELIT NOPRINT BTP1020 COMPUTE CNTSEL/I4 = IF MARKETNAME EQ Amkt OR All THEN 4 BTP1020 ELSE CNT.SELIT ; BTP1020 BY MARKETNAME BTP1020 SUM * BTP1020 COMPUTE BTP1020 SELOW/A50V = EDIT(CNTSEL) | OWNER | EDIT(SELIT); BTP1020 COMPUTE BTP1020 MKTSRT/A104V = IF (CNTSEL EQ 2) BTP1020 THEN EDIT(CNTSEL) | EDIT(SELIT) | MARKETNAME BTP1020 ELSE EDIT(CNTSEL) | MARKETNAME | EDIT(SELIT) ; BTP1020 BY MARKETNAME BTP1020 BY SELIT BTP1020 WHERE TOTAL (CNTSEL EQ 4 OR 3) OR (CNTSEL EQ 2 AND SELIT NE 3) BTP1020 ON TABLE HOLD AS STORSRT BTP1020 -* ON TABLE PCHOLD FORMAT HTML BTP1020 END BTP1020 -SET &SELYEAR=2007; BTP1020 -SET &SELWEEK=45; BTP1020 -SET &PREVYEAR = 2006; BTP1020 -GOTO BYPASS34; BTP1020 -BYPASS34 BTP1020 -*EXIT BTP1020 -*====================================================================================================== BTP1020 -* GET THE SEASONALITY FACTOR BTP1020 TABLE FILE FCT_IndexWeek BTP1020 PRINT COMPUTE INDXVAL/D10.1 = INDEXVALUE * 100; BTP1020 WHERE (YEAR EQ 2007) AND (WEEKNUMBER EQ 45); BTP1020 ON TABLE SAVE AS INDXSAV BTP1020 END BTP1020 -RUN BTP1020 ALPHANUMERIC RECORD NAMED INDXSAV BTP1020 0 FIELDNAME ALIAS FORMAT LENGTH BTP1020 INDEXVALUE IndexValue P10.5 10 BTP1020 INDXVAL D10.1 10 BTP1020 TOTAL 20 BTP1020 -READ INDXSAV &X.A10 &SEAFAC.A10 BTP1020 -RUN
you have too many AFTER MATCH statements - there are three files being matched, and you have three AFTER MATCH statements, you should have only two.
And you should have a -RUN statement after every END statement, if only to execute the stacked commands and immediately get the error, if there is one. The "UNRECOGNIZED COMMAND" would most likely be displayed immediately after the MATCH command instead of later in the program, causing confusion.
Francis
Give me code, or give me retirement. In FOCUS since 1991
Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
Thanks for the information Francis. It's my first attempt at debugging somebody's code I inherited in RC. I guess we all encounter it sooner or later. I'll get back to you on the results.
I will add this to the discussion. ReportCaster is very unforgiving on errors or warnings. We get the Unrecognized Command a lot. We use Textpad to edit fexs and I think sometimes it puts in a hidden control character or a bad carriage control. The programs run fine through our self-service app, but the minute you run through reportcaster it complains. Also, it's very had to isolate because where you get it in the output depends on -runs or -reads and such.
Thanks for the information. Mine also run fine in the self-service app but had to add a few DEFINE's and other things to get it working in RC. Now the problem I see is the programs that have already been programmed and are candidates for RC will have to have extra time allowed before Production Ready. Maybe someone can explain why the programs are different in the two areas (Managed Reporting and Report Caster). I guess it obviously doesn't compile the same.
Harris MRP you're right - one of the non dev studio editors text,word or note pad tends to stick two characters at the beginning of file under what circumstances I don't know but this is definitely a problem we encounter.
Server: WF 7.6.2 ( BID/Rcaster) Platform: W2003Server/IIS6/Tomcat/SQL Server repository Adapters: SQL Server 2000/Oracle 9.2 Desktop: Dev Studio 765/XP/Office 2003 Applications: IFS/Jobscope/Maximo
Posts: 888 | Location: Airstrip One | Registered: October 06, 2006
You also have a === that doesn't have a -* in front of it.
quote:
BTP1020 FILE RPTCOL BTP1020 PRINT * BTP1020 BY MARKETNAME BTP1020 BY OWNER BTP1020 AFTER MATCH HOLD AS STORLST OLD-OR-NEW BTP1020 END BTP1020 ========================================================================================= BTP1020 -* GET THE SEASONALITY FACTOR BTP1020 -SET &SELYEAR=2007; BTP1020 -SET &SELWEEK=45;
About the editor, using tabs used to cause problems with WebFocus, I haven't tested it in more recent versions I've just gotten into the habit of not using it.This message has been edited. Last edited by: PBrightwell,
Pat WF 7.6.8, AIX, AS400, NT AS400 FOCUS, AIX FOCUS, Oracle, DB2, JDE, Lotus Notes
Posts: 755 | Location: TX | Registered: September 25, 2007