Focal Point Banner


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.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Error message the description cannot be found

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Error message the description cannot be found
 Login/Join
 
<GGOFAnalyst>
posted
I keep getting an error saying THE DESCRIPTION CANNOT BE FOUND FOR FILE NAMED: SUBACROSS.

I've tried to fix it but other errors occur. Once I fix those errors then the same error comes back.

Any suggestions?

Here's part of the code

SET PAGE-NUM = OFF;
SET ASNAMES = ON
SET EMPTYREPORT = ON
SET HOLDFORMAT=ALPHA
SET HOLDLIST=PRINTONLY
-SET &ECHO = ON;
-SET &RPTNAME = 'nfphsubr';
-SET &TODAY = &YYMD;
-SET &TODAY = EDIT(&TODAY,'9999/99/99');
-SET &NOW = &TODAY | ' ' | &TOD;

-DEFAULT &DATE_FROM = '&TODAY.EVAL';
-DEFAULT &DATE_TO = '&DATE_FROM.EVAL';
-DEFAULT &FORMAT = 'HTML';
-DEFAULT &SELGB = '';
-DEFAULT &USERTYPE = '';
-DEFAULT &RGN1 = '99999';
-DEFAULT &DATE1 = 'DDATE';
-DEFAULT &ONE_DAY = '';

-SET &RGN2 = '&RGN1.EVAL';

-******************************************************************************
-* Extract User Profile
-******************************************************************************
-INCLUDE FEIPROF1
-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;

-SET &RGN2 = '&RGN1.EVAL';
-SET &WHERERGN = IF &RGN2 EQ 'ALL' THEN ' ' ELSE 'WHERE REGION EQ ''&RGN2.EVAL'';';

-SET &WHEREPOS=IF &USERTYPE EQ 'CSDS' THEN 'WHERE CRBY.POSITION EQ ''Contact / Dealer Support'' OR POSITION EQ ''Contact / Dealer Support 2'';'
-ELSE IF &USERTYPE EQ 'RSM' THEN 'WHERE OWN.POSITION EQ ''RSM'';'
-ELSE IF &USERTYPE EQ 'ISR' THEN 'WHERE CRBY.POSITION EQ ''ISR'';'
-ELSE IF &USERTYPE EQ 'SC' THEN 'WHERE CRBY.POSITION EQ ''Coordinator'';'
-ELSE 'WHERE POSITION NOT CONTAINS ''Temp'';';

-******************************************************************************
-* Setup Output Format Parameters
-******************************************************************************
-SET &FORMATOUT=DECODE &FORMAT(
-'PDF' 'ON TABLE SET ONLINE-FMT PDF'
-'EXCEL' 'ON TABLE SET ONLINE-FMT EXL2K'
-ELSE 'ON TABLE HOLD AS HTMLOUT FORMAT HTMTABLE');

-SET &RSMPRNT = IF &SELGB EQ 'RESULT' THEN 'NOPRINT' ELSE '';
-SET &RSMPRNT1 = IF &SELGB EQ 'CREATEDBYNAME' THEN 'NOPRINT' ELSE '';
-SET &RSMPRNT2 = IF &SELGB EQ 'REGION' THEN 'NOPRINT' ELSE '';
-SET &RSMPRNT5 = IF &DATE1 EQ 'CDATE' THEN '' ELSE 'NOPRINT';
-SET &BYDATE = IF &RSMPRNT5 EQ 'NOPRINT' THEN 'DUEDATE' ELSE 'DATECREATED';

-******************************************************************************
-* Setup Date Parameters
-******************************************************************************
-SET &SEL_DATE = IF &DATE1 EQ 'CDATE' THEN 'CREATEDON' ELSE IF &DATE1 EQ 'DDATE' THEN 'SCHEDULEDSTART';
-SET &SEL_DATE1 = IF &DATE1 EQ 'CDATE' THEN 'CREATEDON' ELSE IF &DATE1 EQ 'DDATE' THEN 'ACTUALSTART';
-SET &SEL_DATE2 = IF &DATE1 EQ 'CDATE' THEN 'CREATEDON' ELSE IF &DATE1 EQ 'DDATE' THEN 'SCHEDULEDEND';
-SET &SEL_DATE3 = IF &DATE1 EQ 'CDATE' THEN 'CREATE_DT_CORRECTED' ELSE IF &DATE1 EQ 'DDATE' THEN 'START_DT_CORRECTED';

-******************************************************************************
-* Determine GMT Offset Hours
-******************************************************************************
-SET &CORR_HOURS = &&OFFSETHOURS;

-******************************************************************************
-* Setup Parameters
-******************************************************************************
TABLE FILE TIME
PRINT
COMPUTE LD1/A10 = EDIT('&DATE_FROM.EVAL', '9999999999'); NOPRINT
COMPUTE F_YYYY/A4 = SUBSTR(10, LD1, 1, 4, 4,'A4'); NOPRINT
COMPUTE F_MM/A2 = SUBSTR(10, LD1, 6, 7, 2, 'A2'); NOPRINT
COMPUTE F_DD/A2 = SUBSTR(10, LD1, 9, 10, 2, 'A2'); NOPRINT
COMPUTE F_YYMD/A8 = F_YYYY||F_MM||F_DD; NOPRINT
COMPUTE F_YYMD2/A8YYMD = F_YYMD; NOPRINT
COMPUTE START_RNG/YYMD = F_YYMD2;
DATE NOPRINT
COMPUTE LD2/A10 = EDIT('&DATE_TO.EVAL', '9999999999'); NOPRINT
COMPUTE T_YYYY/A4 = SUBSTR(10, LD2, 1, 4, 4,'A4'); NOPRINT
COMPUTE T_MM/A2 = SUBSTR(10, LD2, 6, 7, 2, 'A2'); NOPRINT
COMPUTE T_DD/A2 = SUBSTR(10, LD2, 9, 10, 2, 'A2'); NOPRINT
COMPUTE T_YYMD/A8 = T_YYYY||T_MM||T_DD; NOPRINT
COMPUTE T_YYMD2/A8YYMD = T_YYMD; NOPRINT
COMPUTE END_RNG/YYMD = T_YYMD2;
WHERE READLIMIT EQ 1
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE SAVE AS TIMETABLE
END
-RUN

-READ TIMETABLE &SRNG.A8. &ERNG.A8.

TABLE FILE MSEXT_CONTACTVIEW
PRINT
FULLNAME NOPRINT
-*To take care of the end date - When user pics From & To
COMPUTE ERNG_DT_CORRECTED/HYYMDS = HADD(DT(&ERNG.EVAL 23:59:59.999), 'HOUR', -(&CORR_HOURS), 8, 'HYYMDS');
-*To take care of the end date - When user picks as at
COMPUTE SRNG_DT_CORRECTED/HYYMDS = HADD(DT(&SRNG.EVAL 23:59:59.999), 'HOUR', -(&CORR_HOURS), 8, 'HYYMDS');
WHERE READLIMIT EQ 1
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE SAVE AS TIMETABLE1
END
-RUN

-READ TIMETABLE1 &ERNG1.A8. &TIME1.A9. &SRNG1.A8. &TIME2.A9.

-* As at
-TYPE &SRNG
-TYPE &SRNG1

-* From to
-TYPE &SRNG
-TYPE &ERNG1

-* Final
-TYPE &SRNG
-TYPE &ERNG

-SET &WHEREDATE1 = IF &ONE_DAY EQ '' THEN
-'WHERE CREATEDON FROM DT(&SRNG.EVAL 00:00:00.000) TO DT(&ERNG1.EVAL 23:59:59.999);'
-ELSE 'WHERE CREATEDON FROM DT(&SRNG.EVAL 00:00:00.000) TO DT(&SRNG1.EVAL 23:59:59.999);';

-******************************************************************************
-* Setup Region Selection Based On User's Profile
-******************************************************************************
-SET &SEL_RGN = document.forms[0].RGN[document.forms[0].RGN.selectedIndex].value;

-******************************************************************************
-* Setup Heading
-******************************************************************************
-SET &HEADING1 = IF &USERTYPE EQ 'ISR' THEN 'ISR Phone Call Subject Summary'
- ELSE IF &USERTYPE EQ 'RSM' THEN 'RSM Phone Call Subject Summary'
- ELSE IF &USERTYPE EQ 'CSDS' THEN 'CSDS Phone Call Subject Summary'
- ELSE IF &USERTYPE EQ 'SC' THEN 'Sales Coordinator Phone Call Subject Summary'
- ELSE 'All Users Phone Call Subject Summaries';

-SET &HEADING = IF &ONE_DAY EQ 'YES' OR &DATE_FROM EQ &DATE_TO
-THEN &HEADING1 | ' as at: &DATE_FROM.EVAL'
-ELSE &HEADING1 | ' from &DATE_FROM.EVAL to &DATE_TO.EVAL';

-******************************************************************************
-* Setup Date For Footing
-******************************************************************************
-SET &RUN_DATEX = CHGDAT('YYMD', 'MXDYY', &YYMD, 'A17');
-SET &RUN_DATE = LCWORD(&RUN_DATEX.LENGTH, &RUN_DATEX, 'A17');
-SET &RUN_TIME = HHMMSS('A8');

-******************************************************************************
-* Setup Report Footing
-******************************************************************************
-SET &FOOTING =
- 'Report ID: nfphsubr' ||
- ( ' / Report Date: ' | &RUN_DATE ) ||
- ( ' / Report Time: ' | &RUN_TIME ) ||
- ( ' / Page: ' || '
TABLE FILE MSCRM_STRINGMAP
PRINT
ATTRIBUTENAME
ATTRIBUTEVALUE
VALUE
COMPUTE SUBJECT/A255 = IF VALUE EQ '-Pick a Subject-' THEN 'MISSINGSUBJECT'
ELSE IF VALUE EQ 'ACB' THEN 'ACB'
ELSE IF VALUE EQ 'Account Inquiry' THEN 'ACCOUNTINQUIRY'
ELSE IF VALUE EQ 'Dealer Rep kit Request' THEN 'DEALERREPKITREQUEST'
ELSE IF VALUE EQ 'DIP (Outgoing)' THEN 'DIPOUTGOING'
ELSE IF VALUE EQ 'DSC Full Report' THEN 'DSCFULLREPORT'
ELSE IF VALUE EQ 'DSC Inquiry' THEN 'DSCINQUIRY'
ELSE IF VALUE EQ 'DSC Refund' THEN 'DSCREFUND'
ELSE IF VALUE EQ 'Full Free Unit Report' THEN 'FULLFREEUNITREPORT'
ELSE IF VALUE EQ 'Full Trial Balance Report' THEN 'FULLTRIALBALANCEREPORT'
ELSE IF VALUE EQ 'Income Trusts' THEN 'INCOMETRUSTS'
ELSE IF VALUE EQ 'Marketing Fulfillment' THEN 'MARKETINGFULFILLMENT'
ELSE IF VALUE EQ 'Other' THEN 'OTHER'
ELSE IF VALUE CONTAINS 'PPN' THEN 'PPNSLINKNOTES'
ELSE IF VALUE EQ 'Product Inquiry' THEN 'PRODUCTINQUIRY'
ELSE IF VALUE EQ 'Statement Request' THEN 'STATEMENTREQUEST'
ELSE IF VALUE EQ 'Tax Inquiry' THEN 'TAXINQUIRY'
ELSE IF VALUE EQ 'Flow Through' THEN 'FLOWTHROUGH'
ELSE IF VALUE EQ 'Market Conditions' THEN 'MARKETCONDITIONS'
ELSE IF VALUE EQ 'Book Meeting' THEN 'BOOKMEETING'
ELSE IF VALUE EQ 'Follow-up' THEN 'FOLLOWUP'
ELSE IF VALUE EQ 'Fund Campaign' THEN 'FUNDCAMPAIGN'
ELSE IF VALUE EQ 'Introduction' THEN 'INTRODUCTION'
ELSE IF VALUE EQ 'Information Change' THEN 'INFORMATIONCHANGE'
ELSE IF VALUE EQ 'Marketing' THEN 'MARKETING'
ELSE IF VALUE EQ 'Problem Resolution' THEN 'PROBLEMRESOLUTION'
ELSE IF VALUE EQ 'RSM Project' THEN 'RSMPROJECT'
ELSE IF VALUE EQ 'Rep Complaint' THEN 'REPCOMPLAINT'
ELSE IF VALUE EQ 'Rep Request/Change Meeting' THEN 'REPREQUESTCHANGEMEETING'
ELSE IF VALUE EQ 'Rep Inquiry' THEN 'REPINQUIRY'
ELSE IF VALUE EQ 'Thank You' THEN 'THANKYOU'
ELSE IF VALUE EQ 'Rep Request Promos' THEN 'REPREQUESTPROMOS'
ELSE IF VALUE EQ 'Income Trusts' THEN 'INCOMETRUSTS'
ELSE IF VALUE EQ 'Prospectus' THEN 'PROSPECTUS'
ELSE IF VALUE EQ 'Due Diligence' THEN 'DUEDILIGENCE'
ELSE VALUE;
WHERE OBJECTTYPECODE = 4210 AND ATTRIBUTENAME EQ 'cf_subjectclientservices' OR ATTRIBUTENAME EQ 'cf_subjectsales'
BY ATTRIBUTEVALUE NOPRINT
ON TABLE HOLD AS SUBJECTS
END

JOIN VALUE IN SUBJECTS TO ALL SUBJECT IN MSCRM_PHONECALL AS J1

TABLE FILE SUBJECTS
SUM
CNT.SUBJECT AS 'Subjects'
MAX.CREATEDBYNAME
OWNERID
CREATEDBY
REGARDINGOBJECTID
REGARDINGOBJECTTYPECODE
&WHEREDATE1
BY CREATEDBY
BY SUBJECT
ON TABLE HOLD AS COUNTSUB
END

TABLE FILE MSEXT_SYSTEMUSERVIEW
PRINT
SYSTEMUSERID
POSITION
BY SYSTEMUSERID NOPRINT
ON TABLE HOLD AS ISRID
END

-******************************************************************************
-* Extract User Profile
-******************************************************************************
-INCLUDE FEIPROF1
-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;

-******************************************************************************
-* Generate Report
-******************************************************************************
SET NODATA = 0
-*JOIN CREATEDBY IN COUNTSUB TO SYSTEMUSERID IN ISRID AS J2
-*JOIN CREATEDBY IN COUNTSUB TO ALL SYSTEMUSERID IN MSEXT_CRMTEAMCOVERAGEVIEW AS J3
JOIN CREATEDBY IN COUNTSUB TO SYSTEMUSERID IN CRMSYSTEMUSER TAG CRBY AS J4
JOIN OWNERID IN COUNTSUB TO SYSTEMUSERID IN CRMSYSTEMUSER TAG OWN AS J5
JOIN REGARDINGOBJECTID IN COUNTSUB TO CONTACTID IN MSEXT_CONTACTVIEW TAG CON AS J6

TABLE FILE COUNTSUB
PRINT *
COMPUTE REGION1/A300=IF REGARDINGOBJECTTYPECODE EQ 2 THEN CON.CF_REGIONNAME ELSE OWN.BUSINESSUNITIDNAME; AS 'REGION'
REGARDINGOBJECTTYPECODE
&WHEREPOS
ON TABLE HOLD AS CHECK
END

TABLE FILE CHECK
PRINT
CREATEDBYNAME
REGION
&WHERERGN
ON TABLE HOLD AS CHECK2
END

-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;
-IF &LINES = 0 THEN GOTO NOREPORT ELSE GOTO PRINTOUT;
-NOREPORT

TABLE FILE MSEXT_CONTACTVIEW
PRINT
FULLNAME NOPRINT
WHERE RECORDLIMIT EQ 1

-GOTO HSTYLE
-PRINTOUT

SET NODATA = 0
TABLE FILE COUNTSUB
SUM
MAX.SUBJECTS &RSMPRNT.EVAL AS ''
COMPUTE REGION1/A300=IF REGARDINGOBJECTTYPECODE EQ 2 THEN CON.CF_REGIONNAME ELSE OWN.BUSINESSUNITIDNAME; NOPRINT
ACROSS SUBJECT AS ''
BY REGION
BY CREATEDBYNAME &RSMPRNT1.EVAL
&WHEREPOS
-*&WHERERGN
WHERE SYSTEMUSERID NE ' ' AND SUBJECTS NE 0;
ON TABLE HOLD AS SUBACROSS
END

CHECK FILE SUBACROSS HOLD
-RUN

FILEDEF HOLD1 DISK HOLD1.FEX
-RUN

TABLE FILE HOLD
PRINT
FIELDNAME
COMPUTE ASNAME/A100 = IF FIELDNAME EQ 'CREATEDBYNAME' THEN 'AS ''Created By'''
ELSE IF FIELDNAME EQ 'MISSINGSUBJECT' THEN 'AS ''Missing Subject'''
ELSE IF FIELDNAME EQ 'ACB' THEN 'AS ''ACB'''
ELSE IF FIELDNAME EQ 'ACCOUNTINQUIRY' THEN 'AS ''Account Inquiry'''
ELSE IF FIELDNAME EQ 'DEALERREPKITREQUEST' THEN 'AS ''Dealer Rep Kit Request'''
ELSE IF FIELDNAME EQ 'DIPOUTGOING' THEN 'AS ''DIP (Outgoing)'''
ELSE IF FIELDNAME EQ 'DSCFULLREPORT' THEN 'AS ''DSC Full Report'''
ELSE IF FIELDNAME EQ 'DSCINQUIRY' THEN 'AS ''DSC Inquiry'''
ELSE IF FIELDNAME EQ 'DSCREFUND' THEN 'AS ''DSC Refund'''
ELSE IF FIELDNAME EQ 'FULLFREEUNITREPORT' THEN 'AS ''Full Free Unit Report'''
ELSE IF FIELDNAME EQ 'FULLTRIALBALANCEREPORT' THEN 'AS ''Full Trial Balance Report'''
ELSE IF FIELDNAME EQ 'INCOMETRUSTS' THEN 'AS ''Income Trusts'''
ELSE IF FIELDNAME EQ 'MARKETINGFULFILLMENT' THEN 'AS ''Marketing Fulfillment'''
ELSE IF FIELDNAME EQ 'OTHER' THEN 'AS ''Other'''
ELSE IF FIELDNAME EQ 'PPNSLINKNOTES' THEN 'AS ''PPNs (Link Notes)'''
ELSE IF FIELDNAME EQ 'PRODUCTINQUIRY' THEN 'AS ''Product Inquiry'''
ELSE IF FIELDNAME EQ 'STATEMENTREQUEST' THEN 'AS ''Statement Request'''
ELSE IF FIELDNAME EQ 'TAXINQUIRY' THEN 'AS ''Tax Inquiry'''
ELSE IF FIELDNAME EQ 'FLOWTHROUGH' THEN 'AS ''Flow Through'''
ELSE IF FIELDNAME EQ 'MARKETCONDITIONS' THEN 'AS ''Market Conditions'''
ELSE IF FIELDNAME EQ 'BOOKMEETING' THEN 'AS ''Book Meeting'''
ELSE IF FIELDNAME EQ 'FOLLOWUP' THEN 'AS ''Follow-up'''
ELSE IF FIELDNAME EQ 'FUNDCAMPAIGN' THEN 'AS ''Fund Campaign'''
ELSE IF FIELDNAME EQ 'INTRODUCTION' THEN 'AS ''Introduction'''
ELSE IF FIELDNAME EQ 'INFORMATIONCHANGE' THEN 'AS ''Information Change'''
ELSE IF FIELDNAME EQ 'MARKETING' THEN 'AS ''Marketing'''
ELSE IF FIELDNAME EQ 'PROBLEMRESOLUTION' THEN 'AS ''Problem Resolution'''
ELSE IF FIELDNAME EQ 'RSMPROJECT' THEN 'AS ''RSM Project'''
ELSE IF FIELDNAME EQ 'REPCOMPLAINT' THEN 'AS ''Rep Complaint'''
ELSE IF FIELDNAME EQ 'REPREQUESTCHANGEMEETING' THEN 'AS ''Rep Request/Change Meeting'''
ELSE IF FIELDNAME EQ 'REPINQUIRY' THEN 'AS ''Rep Inquiry'''
ELSE IF FIELDNAME EQ 'THANKYOU' THEN 'AS ''Thank You'''
ELSE IF FIELDNAME EQ 'REPREQUESTPROMOS' THEN 'AS ''Rep Request Promos'''
ELSE IF FIELDNAME EQ 'INCOMETRUSTS' THEN 'AS ''Income Trusts'''
ELSE IF FIELDNAME EQ 'PROSPECTUS' THEN 'AS ''Prospectus'''
ELSE IF FIELDNAME EQ 'DUEDILIGENCE' THEN 'AS ''Due Diligence'''
ELSE 'AS ' | FIELDNAME;
WHERE FIELDNAME NE 'REGION1'
ON TABLE HOLD AS HOLD1
END
-RUN

-IF &USERTYPE EQ 'CSDS' THEN GOTO SUBCS
-ELSE IF &USERTYPE IN ('RSM', 'ISR', 'SC') THEN GOTO SUBSALES
-ELSE GOTO SUBALL;

-SUBCS
TABLE FILE SUBACROSS
PRINT
-MRNOEDIT -INCLUDE HOLD1
BY REGION NOPRINT
ON TABLE ROW-TOTAL/D15 AS 'Total'
ON REGION1 SUBHEAD
"&WHERERGN
 
Report This Post
Virtuoso
posted Hide Post
-GOTO HSTYLE

Could this line be your problem?


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
 
Posts: 1903 | Location: San Antonio | Registered: February 28, 2005Report This Post
Expert
posted Hide Post
One of my Golden Rules:

Stick a -RUN after every END statement so that the WebFOCUS code gets put in the stack (don't ask!) before the Dialogue Manager command gets executed. This way, the TABLE FILE commands will actually get executed before the -GOTO does. I don't know if this will solve the problem, but this what I always do.


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
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Expert
posted Hide Post
You have a variable refering to a javascript assignment without quotes - does this work OK?
-SET &SEL_RGN = document.forms[0].RGN[document.forms[0].RGN.selectedIndex].value;

You also have a multi line DM SET without an end semi colon - although this looks like a posting error?
SET &FOOTING =
- 'Report ID: nfphsubr' ||
- ( ' / Report Date: ' | &RUN_DATE ) ||
- ( ' / Report Time: ' | &RUN_TIME ) ||
- ( ' / Page: ' || '

The lines -
END

-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;

will not act as you expect, as the &FOCERRNUM will not be set at that point, it will be the value from a previous point. To get it right add a -RUN after the END statement (a la Francis).

Whilst DM statements are perfectly OK within a table request, your code at the -GOTO HSTYLE (as Prarie pointed out) is syntactically incorrect (should have a semi colon) and there is no END statement finishing off the prior TABLE request before starting the next one -
TABLE FILE MSEXT_CONTACTVIEW
PRINT 
FULLNAME NOPRINT
WHERE RECORDLIMIT EQ 1

-GOTO HSTYLE
-PRINTOUT

SET NODATA = 0
TABLE FILE COUNTSUB
SUM
MAX.SUBJECTS &RSMPRNT.EVAL AS ''

The code at BY CREATEDBYNAME &RSMPRNT1.EVAL is OK as it is although if &RSMPRNT1 is not evaluated as NOPRINT, WF will have a problem with the code BY CREATEDBYNAME CREATEDBYNAME.

I would also be inclined to change the COMPUTE ASNAME/A100 to be a decode and also change the A100 to a value that actually reflects the real length of the string that you are going to populate it with. I would also do the same to SUBJECT further up but you would need to add a CONTAINS to that as well.

That's after a quick run through so try it again after sorting out some basic syntax rule errors and the &FOCERRNUM processing error. Then let us know what you get.

A couple of methods of testing for errors in a program like this is to add

-RUN
-? &
-EXIT

after dialogue manager sections to check the variables are being populated as you require,

-RUN
-* If it is a basic hold file
?F holdfile_name
-* If it is a FOCUS type file
? FILE holdfile_name
-* to check the actually masterfile description produced
!TYPE holdfile_name.MAS
-EXIT

after sections of code where you are populating a temporary table to ensure that the field names and lengths are as you expect.

As you check each section of code, remove the -EXIT and then progress onto the next section until you hit the area that is really causing you the problem Smiler

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, 2004Report This Post
<GGOFAnalyst>
posted
Thanks for your help...I've made some changes in terms of syntax.
I'm new to focus so I'm not too sure about the syntax.
However, my problem hasn't been resolved yet. I'm doing the testing methods to see what's wrong.
 
Report This Post
<GGOFAnalyst>
posted
Ok all my errors are fixed.
Now my problem is my program doesn't show the region. It works fine except it doesn't show the region and my problem is in this part of the program.

-SET NODATA = 0
TABLE FILE COUNTSUB
SUM
MAX.SUBJECTS &RSMPRNT.EVAL AS ''
COMPUTE REGION1/A300=IF REGARDINGOBJECTTYPECODE EQ 2 THEN CON.CF_REGIONNAME ELSE OWN.BUSINESSUNITIDNAME; NOPRINT
ACROSS SUBJECT AS ''
BY REGION1
BY CREATEDBYNAME &RSMPRNT1.EVAL
-&WHEREPOS
-&WHERERGN
WHERE SUBJECTS NE 0;
ON TABLE HOLD AS SUBACROSS
END
-RUN

But here's all of the program that I've fixed.

TABLE FILE MSCRM_STRINGMAP
PRINT
ATTRIBUTENAME
ATTRIBUTEVALUE
VALUE
COMPUTE SUBJECT/A255 = IF VALUE EQ '-Pick a Subject-' THEN 'MISSINGSUBJECT'
ELSE IF VALUE EQ 'ACB' THEN 'ACB'
ELSE IF VALUE EQ 'Account Inquiry' THEN 'ACCOUNTINQUIRY'
ELSE IF VALUE EQ 'Dealer Rep kit Request' THEN 'DEALERREPKITREQUEST'
ELSE IF VALUE EQ 'DIP (Outgoing)' THEN 'DIPOUTGOING'
ELSE IF VALUE EQ 'DSC Full Report' THEN 'DSCFULLREPORT'
ELSE IF VALUE EQ 'DSC Inquiry' THEN 'DSCINQUIRY'
ELSE IF VALUE EQ 'DSC Refund' THEN 'DSCREFUND'
ELSE IF VALUE EQ 'Full Free Unit Report' THEN 'FULLFREEUNITREPORT'
ELSE IF VALUE EQ 'Full Trial Balance Report' THEN 'FULLTRIALBALANCEREPORT'
ELSE IF VALUE EQ 'Income Trusts' THEN 'INCOMETRUSTS'
ELSE IF VALUE EQ 'Marketing Fulfillment' THEN 'MARKETINGFULFILLMENT'
ELSE IF VALUE EQ 'Other' THEN 'OTHER'
ELSE IF VALUE CONTAINS 'PPN' THEN 'PPNSLINKNOTES'
ELSE IF VALUE EQ 'Product Inquiry' THEN 'PRODUCTINQUIRY'
ELSE IF VALUE EQ 'Statement Request' THEN 'STATEMENTREQUEST'
ELSE IF VALUE EQ 'Tax Inquiry' THEN 'TAXINQUIRY'
ELSE IF VALUE EQ 'Flow Through' THEN 'FLOWTHROUGH'
ELSE IF VALUE EQ 'Market Conditions' THEN 'MARKETCONDITIONS'
ELSE IF VALUE EQ 'Book Meeting' THEN 'BOOKMEETING'
ELSE IF VALUE EQ 'Follow-up' THEN 'FOLLOWUP'
ELSE IF VALUE EQ 'Fund Campaign' THEN 'FUNDCAMPAIGN'
ELSE IF VALUE EQ 'Introduction' THEN 'INTRODUCTION'
ELSE IF VALUE EQ 'Information Change' THEN 'INFORMATIONCHANGE'
ELSE IF VALUE EQ 'Marketing' THEN 'MARKETING'
ELSE IF VALUE EQ 'Problem Resolution' THEN 'PROBLEMRESOLUTION'
ELSE IF VALUE EQ 'RSM Project' THEN 'RSMPROJECT'
ELSE IF VALUE EQ 'Rep Complaint' THEN 'REPCOMPLAINT'
ELSE IF VALUE EQ 'Rep Request/Change Meeting' THEN 'REPREQUESTCHANGEMEETING'
ELSE IF VALUE EQ 'Rep Inquiry' THEN 'REPINQUIRY'
ELSE IF VALUE EQ 'Thank You' THEN 'THANKYOU'
ELSE IF VALUE EQ 'Rep Request Promos' THEN 'REPREQUESTPROMOS'
ELSE IF VALUE EQ 'Income Trusts' THEN 'INCOMETRUSTS'
ELSE IF VALUE EQ 'Prospectus' THEN 'PROSPECTUS'
ELSE IF VALUE EQ 'Due Diligence' THEN 'DUEDILIGENCE'
ELSE VALUE;
WHERE OBJECTTYPECODE = 4210 AND ATTRIBUTENAME EQ 'cf_subjectclientservices' OR ATTRIBUTENAME EQ 'cf_subjectsales'
BY ATTRIBUTEVALUE NOPRINT
ON TABLE HOLD AS SUBJECTS
END
-RUN

JOIN VALUE IN SUBJECTS TO ALL SUBJECT IN MSCRM_PHONECALL AS J1

TABLE FILE SUBJECTS
SUM
CNT.SUBJECT AS 'Subjects'
MAX.CREATEDBYNAME
OWNERID
CREATEDBY
REGARDINGOBJECTID
REGARDINGOBJECTTYPECODE
&WHEREDATE1
BY CREATEDBY
BY SUBJECT
ON TABLE HOLD AS COUNTSUB
END
-RUN

TABLE FILE MSEXT_SYSTEMUSERVIEW
PRINT
SYSTEMUSERID
POSITION
BY SYSTEMUSERID NOPRINT
ON TABLE HOLD AS ISRID
END
-RUN

-******************************************************************************
-* Extract User Profile
-******************************************************************************
-INCLUDE FEIPROF1
-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;

-******************************************************************************
-* Generate Report
-******************************************************************************
SET NODATA = 0
-*JOIN CREATEDBY IN COUNTSUB TO SYSTEMUSERID IN ISRID AS J2
-*JOIN CREATEDBY IN COUNTSUB TO ALL SYSTEMUSERID IN MSEXT_CRMTEAMCOVERAGEVIEW AS J3
JOIN CREATEDBY IN COUNTSUB TO SYSTEMUSERID IN CRMSYSTEMUSER TAG CRBY AS J4
JOIN OWNERID IN COUNTSUB TO SYSTEMUSERID IN CRMSYSTEMUSER TAG OWN AS J5
JOIN REGARDINGOBJECTID IN COUNTSUB TO CONTACTID IN MSEXT_CONTACTVIEW TAG CON AS J6

TABLE FILE COUNTSUB
PRINT *
COMPUTE REGION1/A300=IF REGARDINGOBJECTTYPECODE EQ 2 THEN CON.CF_REGIONNAME ELSE OWN.BUSINESSUNITIDNAME; AS 'REGION'
REGARDINGOBJECTTYPECODE
&WHEREPOS
ON TABLE HOLD AS CHECK
END
-RUN

TABLE FILE CHECK
PRINT
CREATEDBYNAME
REGION
-*&WHERERGN
ON TABLE HOLD AS CHECK2
END
-RUN

-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;
-IF &LINES = 0 THEN GOTO NOREPORT ELSE GOTO PRINTOUT;
-NOREPORT

TABLE FILE MSEXT_CONTACTVIEW
PRINT
FULLNAME NOPRINT
WHERE RECORDLIMIT EQ 1

-GOTO HSTYLE
-PRINTOUT

-SET NODATA = 0
TABLE FILE COUNTSUB
SUM
MAX.SUBJECTS &RSMPRNT.EVAL AS ''
COMPUTE REGION1/A300=IF REGARDINGOBJECTTYPECODE EQ 2 THEN CON.CF_REGIONNAME ELSE OWN.BUSINESSUNITIDNAME; NOPRINT
ACROSS SUBJECT AS ''
BY REGION1
BY CREATEDBYNAME &RSMPRNT1.EVAL
-&WHEREPOS
-&WHERERGN
WHERE SUBJECTS NE 0;
ON TABLE HOLD AS SUBACROSS
END
-RUN

CHECK FILE SUBACROSS HOLD
-RUN

FILEDEF HOLD1 DISK HOLD1.FEX
-RUN

TABLE FILE HOLD
PRINT
FIELDNAME
COMPUTE ASNAME/A100 = IF FIELDNAME EQ 'CREATEDBYNAME' THEN 'AS ''Created By'''
ELSE IF FIELDNAME EQ 'MISSINGSUBJECT' THEN 'AS ''Missing Subject'''
ELSE IF FIELDNAME EQ 'ACB' THEN 'AS ''ACB'''
ELSE IF FIELDNAME EQ 'ACCOUNTINQUIRY' THEN 'AS ''Account Inquiry'''
ELSE IF FIELDNAME EQ 'DEALERREPKITREQUEST' THEN 'AS ''Dealer Rep Kit Request'''
ELSE IF FIELDNAME EQ 'DIPOUTGOING' THEN 'AS ''DIP (Outgoing)'''
ELSE IF FIELDNAME EQ 'DSCFULLREPORT' THEN 'AS ''DSC Full Report'''
ELSE IF FIELDNAME EQ 'DSCINQUIRY' THEN 'AS ''DSC Inquiry'''
ELSE IF FIELDNAME EQ 'DSCREFUND' THEN 'AS ''DSC Refund'''
ELSE IF FIELDNAME EQ 'FULLFREEUNITREPORT' THEN 'AS ''Full Free Unit Report'''
ELSE IF FIELDNAME EQ 'FULLTRIALBALANCEREPORT' THEN 'AS ''Full Trial Balance Report'''
ELSE IF FIELDNAME EQ 'INCOMETRUSTS' THEN 'AS ''Income Trusts'''
ELSE IF FIELDNAME EQ 'MARKETINGFULFILLMENT' THEN 'AS ''Marketing Fulfillment'''
ELSE IF FIELDNAME EQ 'OTHER' THEN 'AS ''Other'''
ELSE IF FIELDNAME EQ 'PPNSLINKNOTES' THEN 'AS ''PPNs (Link Notes)'''
ELSE IF FIELDNAME EQ 'PRODUCTINQUIRY' THEN 'AS ''Product Inquiry'''
ELSE IF FIELDNAME EQ 'STATEMENTREQUEST' THEN 'AS ''Statement Request'''
ELSE IF FIELDNAME EQ 'TAXINQUIRY' THEN 'AS ''Tax Inquiry'''
ELSE IF FIELDNAME EQ 'FLOWTHROUGH' THEN 'AS ''Flow Through'''
ELSE IF FIELDNAME EQ 'MARKETCONDITIONS' THEN 'AS ''Market Conditions'''
ELSE IF FIELDNAME EQ 'BOOKMEETING' THEN 'AS ''Book Meeting'''
ELSE IF FIELDNAME EQ 'FOLLOWUP' THEN 'AS ''Follow-up'''
ELSE IF FIELDNAME EQ 'FUNDCAMPAIGN' THEN 'AS ''Fund Campaign'''
ELSE IF FIELDNAME EQ 'INTRODUCTION' THEN 'AS ''Introduction'''
ELSE IF FIELDNAME EQ 'INFORMATIONCHANGE' THEN 'AS ''Information Change'''
ELSE IF FIELDNAME EQ 'MARKETING' THEN 'AS ''Marketing'''
ELSE IF FIELDNAME EQ 'PROBLEMRESOLUTION' THEN 'AS ''Problem Resolution'''
ELSE IF FIELDNAME EQ 'RSMPROJECT' THEN 'AS ''RSM Project'''
ELSE IF FIELDNAME EQ 'REPCOMPLAINT' THEN 'AS ''Rep Complaint'''
ELSE IF FIELDNAME EQ 'REPREQUESTCHANGEMEETING' THEN 'AS ''Rep Request/Change Meeting'''
ELSE IF FIELDNAME EQ 'REPINQUIRY' THEN 'AS ''Rep Inquiry'''
ELSE IF FIELDNAME EQ 'THANKYOU' THEN 'AS ''Thank You'''
ELSE IF FIELDNAME EQ 'REPREQUESTPROMOS' THEN 'AS ''Rep Request Promos'''
ELSE IF FIELDNAME EQ 'INCOMETRUSTS' THEN 'AS ''Income Trusts'''
ELSE IF FIELDNAME EQ 'PROSPECTUS' THEN 'AS ''Prospectus'''
ELSE IF FIELDNAME EQ 'DUEDILIGENCE' THEN 'AS ''Due Diligence'''
ELSE 'AS ' | FIELDNAME;
WHERE FIELDNAME NE 'REGION'
ON TABLE HOLD AS HOLD1
END
-RUN

-IF &USERTYPE EQ 'CSDS' THEN GOTO SUBCS
-ELSE IF &USERTYPE IN ('RSM', 'ISR', 'SC') THEN GOTO SUBSALES
-ELSE GOTO SUBALL;

-SUBCS
TABLE FILE SUBACROSS
PRINT
-MRNOEDIT -INCLUDE HOLD1
BY REGION
ON TABLE ROW-TOTAL/D15 AS 'Total'
ON REGION SUBHEAD
"&WHERERGN
 
Report This Post
Expert
posted Hide Post
Frank is correct although I don't believe in overusing -RUN. But whenever you have Dialog Manager code embedded in Focus code, to ensure that the DM runs at the proper time, you must put the -RUN statements in.

Since you are new to Focus, it is important to understand the parsing order in a focexec. Dialog Manager commands get evaluated first (-commands and &variables). All other commands are placed in focstack. The DM commands are executied first followed by commands in focstack unless the Focus commands are followed by a -RUN which executes the commands in the stack.

This area of your code is questionable:

TABLE FILE CHECK
PRINT
CREATEDBYNAME
REGION
&WHERERGN
ON TABLE HOLD AS CHECK2
END
==> Need a -RUN here.
-IF &FOCERRNUM NE 0 GOTO ACTIVITY_ERR;
-IF &LINES = 0 THEN GOTO NOREPORT ELSE GOTO PRINTOUT;
-NOREPORT

TABLE FILE MSEXT_CONTACTVIEW
PRINT
FULLNAME NOPRINT
WHERE RECORDLIMIT EQ 1 <== This is an incomplete request.

-GOTO HSTYLE <== This label doesn't exist.
-PRINTOUT

The reason you are getting the SUBACROSS not found error is that that hold file is never getting created. You need to trace your DM logic to find out why. Try -SET &ECHO=ALL; instead.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
<GGOFAnalyst>
posted
Thanks for the mini lesson.
However, I didn't post all of my code on here so the HSTYLE does exist, I just didn't post the HTML part of my code.
In my revised code I do have a -RUN at the end of
TABLE FILE CHECK
PRINT
CREATEDBYNAME
REGION
&WHERERGN
ON TABLE HOLD AS CHECK2
END

I've tested this and it works
TABLE FILE MSEXT_CONTACTVIEW
PRINT
FULLNAME NOPRINT
WHERE RECORDLIMIT EQ 1

Those aren't the problems in the program.

This part is
-SET NODATA = 0
TABLE FILE COUNTSUB
SUM
MAX.SUBJECTS &RSMPRNT.EVAL AS ''
COMPUTE REGION1/A300=IF REGARDINGOBJECTTYPECODE EQ 2 THEN CON.CF_REGIONNAME ELSE OWN.BUSINESSUNITIDNAME; NOPRINT
ACROSS SUBJECT AS ''
BY REGION1
BY CREATEDBYNAME &RSMPRNT1.EVAL
-&WHEREPOS
-&WHERERGN
WHERE SUBJECTS NE 0;
ON TABLE HOLD AS SUBACROSS
END
-RUN

It doesn't seem to give an output for region. The report runs but no output for the region.
 
Report This Post
Expert
posted Hide Post
GG,


1) YOU mixcase in the pull: CNT.SUBJECT AS 'Subjects' and MAX.SUBJECTS &RSMPRNT.EVAL AS ''
in subsequent step???
2) Do ?FF COUNTSUB after the TABLE step and after -RUN to see if it is named correctly and actually populated;
If YES, table it out and see if each column is populated, as expected:

-SET &ECHO=ALL;

TABLE FILE SUBJECTS
SUM
CNT.SUBJECT AS 'Subjects'
MAX.CREATEDBYNAME
OWNERID
CREATEDBY
REGARDINGOBJECTID
REGARDINGOBJECTTYPECODE
&WHEREDATE1
BY CREATEDBY
BY SUBJECT
ON TABLE HOLD AS COUNTSUB
END
-RUN

?FF COUNTSUB
-RUN

TABLE FILE COUNTSUB PRINT *
IF RECORDLIMIT EQ 100
END
-EXIT


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Platinum Member
posted Hide Post
I'd suspect that the code should've given you an ERROR message:

BY TOTAL and ACROSS: BY TOTAL key cannot be COMPUTEd

If you comment out ACROSS SUBJECT AS '', does the report still work, if so convert REGION1 from a COMPUTEd field to a DEFINE.
 
Posts: 140 | Registered: May 02, 2007Report This Post
<GGOFAnalyst>
posted
All the columns are populated, I've checked that.

I don't get any error messages. The only thing I get is WARNING: SORTING ON A COMPUTED FIELD % REGION1

I commented out the ACROSS and I don't get any output. No error either.
 
Report This Post
<GGOFAnalyst>
posted
The region shows up now.
DEFINE solved it.
Thanks FortuneCookie.

Now I have other problems to fix! lol
 
Report This Post
Expert
posted Hide Post
GG,

quote:

-&WHEREPOS
-&WHERERGN


These 'ARE NOT' Dialogue Manager statements, remove the dash. In the ECHO, make sure these are the desired WHERE statements you generated at the top. This may be the reaon for ZERO records..

'MAY' need .EVAL:

&WHEREPOS
&WHERERGN


Edit: Never mind!!!!


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
<GGOFAnalyst>
posted
My report works fine now.

I totally forgot that I had put a - next the to the WHEREPOS and WHERERGN. I had commented them out and forgot to take out the -.

Thanks Tom.
 
Report This Post
Member
posted Hide Post
-SET NODATA = 0
what is this?
if a dm command dont you mean -set &nodata = '0';
or if a set command and not dm
dont you mean SET NODATA = 0


Ira wf 5.3.6
 
Posts: 29 | Registered: March 30, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     Error message the description cannot be found

Copyright © 1996-2020 Information Builders