I am trying to use a hold file H_SLS_NAMES as filter of a column but webfocus in giving me an error of file not being allocated. I have tried saving the hold file in the forecache and I am still getting the same error:
0 NUMBER OF RECORDS IN TABLE= 283 LINES= 283 0 ERROR AT OR NEAR LINE 23 IN PROCEDURE ADHOCRQ FOCEXEC * (FOC351) INPUT FILE NOT ALLOCATED: H_SLS_NAMES (FOC009) INCOMPLETE REQUEST STATEMENT BYPASSING TO END OF COMMAND
here is the code:
APP HOLD foccache
TABLE FILE DIM_SALES_REP PRINT DIM_SALES_REP.DIM_SALES_REP.COMPANY DIM_SALES_REP.DIM_SALES_REP.SALES_MAN_CODE ON TABLE SET PAGE-NUM NOLEAD ON TABLE SET BYDISPLAY ON ON TABLE NOTOTAL ON TABLE HOLD AS H_SLS_NAMES FORMAT FOCUS ON TABLE SET HTMLCSS ON ON TABLE SET STYLE * INCLUDE = IBFS:/EDA/EDASERVE/_EDAHOME/ETC/endeflt.sty, $ ENDSTYLE END TABLE FILE DEVIATION_MASTER_FILE PRINT DEVIATION_MASTER_FILE.DEVIATION_MASTER_FILE.OPCOMP DEVIATION_MASTER_FILE.DEVIATION_MASTER_FILE.OPACCT WHERE ( DEVIATION_MASTER_FILE.DEVIATION_MASTER_FILE.OPCOMP IN FILE H_SLS_NAMES ) AND ( DEVIATION_MASTER_FILE.DEVIATION_MASTER_FILE.OPRFDT GE 1160201 ); ON TABLE SET PAGE-NUM NOLEAD ON TABLE NOTOTAL ON TABLE PCHOLD FORMAT HTML ON TABLE SET HTMLCSS ON ON TABLE SET STYLE * INCLUDE = IBFS:/EDA/EDASERVE/_EDAHOME/ETC/endeflt.sty, $ ENDSTYLE END
thanks,
VeraThis message has been edited. Last edited by: <Emily McAllister>,
WebFOCUS DS 8.0.0.9 WebFOCUS AS 8.2.0.1 Iway Data Migrator 8.0.09 Windows, All Outputs
February 08, 2016, 09:23 AM
Francis Mariani
When using a HOLD file as a filter, it can't be a FOCUS DB and it must have only one column.
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
February 08, 2016, 10:11 AM
Vera T
Francis,
Can you please tell me what kind of file should I save it to?
thanks,
Vera
WebFOCUS DS 8.0.0.9 WebFOCUS AS 8.2.0.1 Iway Data Migrator 8.0.09 Windows, All Outputs
February 08, 2016, 10:11 AM
BabakNYC
Try ON TABLE HOLD FORMAT ALPHA
You should also SET HOLDLIST=PRINTONLY SET ASNAME=ON
WebFOCUS 8206, Unix, Windows
February 08, 2016, 11:08 AM
eric.woerle
One other thing, I believe you need to use
ON TABLE SAVE AS H_SLS_NAMES
I never specify format as default format is ALPHA. But as Babak points out, that is the format you will need. You can specify it if you wish.
Also as Francis points out, just include 1 column. If you do that, you wont need to include the set commands that Babak mentions. It seems that you are comparing against COMPANY, so I would remove SALES_MAN_CODE
SET ASNAME=ON will change the Field name of a field for subsequent hold files if you use the "AS" syntax. Your not doing that here, so there is no need. Also since you are using the field as selection criteria, the field name is irrelevant anyways.
SET HOLDLIST=PRINTONLY this is only relevant if you are using a compute, changing the type of the field within the TABLE FILE request, or using the NOPRINT option. Again, you don't have any of those in your request, so this option will be irrelevant as well for you.
One important thing to note when using this though is that it is limited to about 1000 values. I can't remember if this is a database restriction (I use oracle) or a WebFOCUS restriction. But if you have the potential of pulling in a large amount of values to restrict on, you might want to consider other options.This message has been edited. Last edited by: eric.woerle,
Eric Woerle 8.1.05M Gen 913- Reporting Server Unix 8.1.05 Client Unix Oracle 11.2.0.2
February 08, 2016, 01:48 PM
Vera T
Thank for every one. it is working.
WebFOCUS DS 8.0.0.9 WebFOCUS AS 8.2.0.1 Iway Data Migrator 8.0.09 Windows, All Outputs
February 09, 2016, 10:45 AM
George Patton
One final comment: When creating a hold file you don't need any styling attributes whatsoever. It's possible you are using the GUI and it throws them in unnecessarily but to my mind it is just messy coding. (Won't get into the HOLD file in any case).