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     [SOLVED]Can we turn off the auto prompting facility for the &variables ?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED]Can we turn off the auto prompting facility for the &variables ?
 Login/Join
 
Guru
posted
Hi,

Iam using the below code and trying to read the values in a table file
using the readfile command as shown below and later using these values in the Table file request:

 ENGINE SQLORA SET DEFAULT_CONNECTION USER_CONNECT

SQL SQLORA PREPARE REPORT1 FOR
SELECT * FROM SCHM1.V_TABLE1;
END

TABLE FILE REPORT1
PRINT
COLUMN1_1
COLUMN1_2
COLUMN1_3
WHERE REPORT_DATA EQ ''
ON TABLE HOLD AS MYFILE_REPT
END
-RUN

-READFILE MYFILE_REPT
-TYPE &COLUMN1_1
-TYPE &COLUMN1_2
-TYPE &COLUMN1_3

TABLE FILE REPORT1
PRINT
DIVISION
DEPARTMEMT
STATE
COLUMN1_1 AS '&COLUMN1_1'
COLUMN1_2 AS '&COLUMN1_2'
COLUMN1_3 AS '&COLUMN1_3'
EMD
-RUN
-EXIT
 


When I run the report, in the auto prompting facility under parameters, it is prompting to enter the
values for COLUMN1_1,COLUMN1_2 and COLUMN1_3 but I want all these variables to be hidden and not to show up when I run the report.
The report still runs if I click on the Run button under auto prompting facility but somehow I dont want these
variables to show up in the auto prompting facility because it confuses my client/stakeholder saying that these variables need some inputs
to be entered before running the report.

Could anyone please let me know on how to hide these(COLUMN1_1,COLUMN1_2 and COLUMN1_3) in the Auto prompting facility ?

Any help is greatly appreciated. Thanks a lot in advance!

Regards,
IP

This message has been edited. Last edited by: info4pal,


Webfocus 8105 Developer studio,Windows 7,HTML,Excel,PDF,Text,Infoassist,Graph,AHTML
 
Posts: 270 | Registered: October 30, 2014Report This Post
Virtuoso
posted Hide Post
You can either turn off autoprompt entirely for your site (which is probably not what you want), or you can add -DEFAULT's for your variables between the -READFILE and where you first use them.

I don't think there's a way to temporarily disable autoprompt in a section of a fex. I'd love to have a feature like that.


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report This Post
Guru
posted Hide Post
Hi Wep,

I have one default variable(State) which is linked to the parameter page of this report and I haven't mentioned in the code which I had pasted earlier.

May I know how can I turnoff autoprompt entirely and also could you please let me know how can I add DEFAULT's for my variables between the -READFILE.Please help.

Regards,
IP


Webfocus 8105 Developer studio,Windows 7,HTML,Excel,PDF,Text,Infoassist,Graph,AHTML
 
Posts: 270 | Registered: October 30, 2014Report This Post
Virtuoso
posted Hide Post
You need to DEFAULTH all columns that are part of the HOLD file (in your case : MYFILE_REPT).
And I do suggest to add a -RUN after the READFILE
-DEFAULTH &COLUMN1_1 = ''
-DEFAULTH &COLUMN1_2 = ''
-DEFAULTH &COLUMN1_3 = ''

TABLE FILE REPORT1
PRINT
COLUMN1_1
COLUMN1_2
COLUMN1_3
WHERE REPORT_DATA EQ ''
ON TABLE HOLD AS MYFILE_REPT
END
-RUN

-READFILE MYFILE_REPT
-RUN
-TYPE &COLUMN1_1
-TYPE &COLUMN1_2
-TYPE &COLUMN1_3


To turn off auto-prompting, if I don't mistaken, go to BIP / Administration Console / Configuration / Application Settings / Parameter Prompting and I think that you need to set to "ON". But I'm not 100% sure since I have issue with the IBI help display.


WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF
In Focus since 2007
 
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Report This Post
Guru
posted Hide Post
Hi Martin,

Thanks a ton for your help Smiler
It worked!

Regards,
IP


Webfocus 8105 Developer studio,Windows 7,HTML,Excel,PDF,Text,Infoassist,Graph,AHTML
 
Posts: 270 | Registered: October 30, 2014Report This Post
Guru
posted Hide Post
Conversely you can also uncheck the prompt for parameters checkbox on the properties for the report


WF 7.6.11
Oracle
WebSphere
Windows NT-5.2 x86 32bit
 
Posts: 398 | Registered: February 04, 2008Report This Post
Virtuoso
posted Hide Post
quote:
Conversely you can also uncheck the prompt for parameters checkbox on the properties for the report


True, but with WF8, it may not be sufficient, unfortunately.


WF versions : Prod 8.2.04M gen 33, Dev 8.2.04M gen 33, OS : Windows, DB : MSSQL, Outputs : HTML, Excel, PDF
In Focus since 2007
 
Posts: 2409 | Location: Montreal Area, Qc, CA | Registered: September 25, 2013Report This Post
Guru
posted Hide Post
Ah, quelle domage


WF 7.6.11
Oracle
WebSphere
Windows NT-5.2 x86 32bit
 
Posts: 398 | Registered: February 04, 2008Report This Post
Virtuoso
posted Hide Post
quote:
Originally posted by MartinY:
You need to DEFAULTH all columns that are part of the HOLD file (in your case : MYFILE_REPT).
And I do suggest to add a -RUN after the READFILE
-DEFAULTH &COLUMN1_1 = '';
-DEFAULTH &COLUMN1_2 = '';
-DEFAULTH &COLUMN1_3 = '';

TABLE FILE REPORT1
PRINT
COLUMN1_1
COLUMN1_2
COLUMN1_3
WHERE REPORT_DATA EQ ''
ON TABLE HOLD AS MYFILE_REPT
END
-RUN

-READFILE MYFILE_REPT
-RUN
-TYPE &COLUMN1_1
-TYPE &COLUMN1_2
-TYPE &COLUMN1_3



What I was suggesting, which prevents the warning from -READFILE about the parameters being overwritten, is this (notice where the -DEFAULT's went):
TABLE FILE REPORT1
PRINT
COLUMN1_1
COLUMN1_2
COLUMN1_3
WHERE REPORT_DATA EQ ''
ON TABLE HOLD AS MYFILE_REPT
END
-RUN

-READFILE MYFILE_REPT
-DEFAULTH &COLUMN1_1 = ''
-DEFAULTH &COLUMN1_2 = ''
-DEFAULTH &COLUMN1_3 = ''

-RUN
-TYPE &COLUMN1_1
-TYPE &COLUMN1_2
-TYPE &COLUMN1_3


Cred's go to someone else on this forum, but I forgot who taught me this. Sorry and thanks Wink

About adding -RUN after -READFILE; Be very careful with that!

Using -RUN closes any open files. So if you use -READFILE within a loop (-REPEAT or -GOTO), you'll be reading the first line over and over.
Furthermore, if you're only exiting that loop when -READFILE results in an I/O error after the last line - that won't happen! (well, unless you're reading an empty file)

Yeah, been there, stopped doing that.

And another thing I just noticed: -DEFAULT without a closing semi-colon is old-style syntax and is being advised against (note that I'm not an authority on the matter).


WebFOCUS 8.1.03, Windows 7-64/2008-64, IBM DB2/400, Oracle 11g & RDB, MS SQL-Server 2005, SAP, PostgreSQL 11, Output: HTML, PDF, Excel 2010
: Member of User Group Benelux :
 
Posts: 1669 | Location: Enschede, Netherlands | Registered: August 12, 2010Report This Post
Virtuoso
posted Hide Post
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report This Post
Virtuoso
posted Hide Post
quote:
-DEFAULT without a closing semi-colon is old-style syntax


Not so. Although tolerated, it's absent from the documented syntax:
Syntax: How to Supply a Default Value
-DEFAULT &[&]name=value , [&[&]name=value]
where:
&name
Is the name of the variable.
value
Is the default value assigned to the variable.


-- Which makes sense -- semicolon is needed (in -SET, for example) when the expression it delimits can be continued over multiple lines. -DEFAULT cannot.


- Jack Gross
WF through 8.1.05
 
Posts: 1925 | Location: NYC | In FOCUS since 1983 | Registered: January 11, 2005Report 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     [SOLVED]Can we turn off the auto prompting facility for the &variables ?

Copyright © 1996-2020 Information Builders