Focal Point
[CLOSED] Error in SQL code from webfocus define based procedure (InfoAssist)

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

October 15, 2014, 05:00 AM
Avinash
[CLOSED] Error in SQL code from webfocus define based procedure (InfoAssist)
Hi All,

I am working on the SQL code of a Web-focus DEFINE based procedure.
---------------------------------------------------------------------
ENGINE INT CACHE SET ON


-*COMPONENT=Define_TABLE1
DEFINE FILE TABLE1
Define_1/D3=2;
END
-DEFAULTH &WF_SUMMARY='Summary';
-DEFAULTH &WF_TITLE='WebFOCUS Report';
TABLE FILE TABLE1
PRINT CLIENT_CD
Define_1
ON TABLE PCHOLD FORMAT HTML
ON TABLE NOTOTAL
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE SET SQUEEZE ON
ON TABLE SET EMPTYREPORT ON
ON TABLE SET HTMLCSS ON
ON TABLE SET HTMLENCODE ON
ON TABLE SET CACHELINES 100
ON TABLE SET TRACEOFF ALL0
ON TABLE SET TRACEON SQLCALL
ON TABLE SET TRACEON SQLTRANS
ON TABLE SET TRACEON 'SQLAGGR//CLIENT'
ON TABLE SET TRACEON 'STMTRACE//CLIENT'
ON TABLE SET TRACESTAMP OFF
ON TABLE SET TRACEWRAP 78
ON TABLE SET TRACEUSER ON
ON TABLE SET STYLE *
INCLUDE=IBFS:/FILE/IBI_HTML_DIR/javaassist/intl/EN/ENIADefault_combine.sty,$
TYPE=REPORT, TITLETEXT=&WF_TITLE.QUOTEDSTRING, SUMMARY=&WF_SUMMARY.QUOTEDSTRING, ORIENTATION=LANDSCAPE, $
ENDSTYLE
END
------------------------------
Its returning me the SQL code -

< !-- FOC2590 - AGGREGATION NOT DONE FOR THE FOLLOWING REASON: FOC2594 - AGGREGATION IS NOT APPLICABLE TO THE VERB USED SELECT T1."CLIENT_CD" FROM EDW.TABLE1 T1; 0 NUMBER OF RECORDS IN TABLE= 10 LINES= 10 0 HOLDING HTML FILE ON PC DISK ... -->

But it should select the DEFINE field also in the SQL SELECT section. and its not including the DEFINE based filter also.

can any one help me on my both point that how can I generate the SQL code with DEFINE field.

This message has been edited. Last edited by: <Kathryn Henning>,


Thanks!
@vi

WebFOCUS 8105, Dev Studio 8105, Windows 7, ALL Outputs
October 15, 2014, 06:52 AM
Rifaz
As your procedure only has PRINT VERB, there is no request passed to RDBMS to do aggregation. Change to SUM and try. Moreever, its just a message, not an errors. Reports ran successfully in my past expereince, though i got this at the source.

However, as you mentioned specifically in IA, will these errors stopped to execute the reports?


-Rifaz

WebFOCUS 7.7.x and 8.x
October 15, 2014, 07:48 AM
Avinash
Not Working Rifaz..


Thanks!
@vi

WebFOCUS 8105, Dev Studio 8105, Windows 7, ALL Outputs
October 15, 2014, 09:46 AM
Alan B
When using the SUM verb, as Rifaz suggested, what is the SQL returned? Not working does not hack it.


Alan.
WF 7.705/8.007
October 15, 2014, 10:42 AM
Francis Mariani
Since
Define_1/D3=2;
is a constant, it probably will not be passed to SQL. As previously mentioned, the aggregation message is because you're using PRINT not SUM.


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