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. Moving forward, myibi is our community platform to learn, share, and collaborate. We have the same Focal Point forum categories in myibi, so you can continue to have all new conversations there. If you need access to myibi, contact us at myibi@ibi.com and provide your corporate email address, company, and name.


Connect to myibi
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] View generated sql query using view source

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] View generated sql query using view source
 Login/Join
 
Member
posted
Hi,

(new to webfocus)

I am trying to get "view source" of the executed sql code/query.

Action: - trying to get view source code when clicking the EXCEL button (Exported to EXCEL where the query is excuted)


When using the below on the top of the file.

SET XRETRIEVAL=OFF
SET TRACEOFF = ALL
SET TRACEON=STMTRACE
SET TRACEON = SQLAGGR//CLIENT
SET TRACEON = STMTRACE//CLIENT
SET TRACEON = STMTRACE/2/CLIENT
SET TRACEUSER = ON


I get
Error number: -3706


Another option I could think of is saving the query to variable and send it to alert message? But was unsuccessful in getting the query.


the below shows the output of the table.
-*
.......
TABLEF
ON TABLE HOLD AS APPLE FORMAT ALPHA
END
-RUN
-SET &ECHO=OFF;
-HTMLFORM BEGIN
<script>
alert("Query : " + !IBI.FIL.APPLEWink;

-HTMLFORM END
-RUN
-EXIT
-*



Any suggestions.

Thanks.

This message has been edited. Last edited by: FP Mod Chuck,


WEBFOCUS - 8202
OS - Windows
Output - PDF, Excel, HTML, txt.
 
Posts: 9 | Registered: July 27, 2020Report This Post
Virtuoso
posted Hide Post
Phil

Welcome to Focal Point! If you add -SET &ECHO=ALL; as the first line of your fex and after you run it view the source of the output and scroll to the bottom, it will display the SQL generated. Your output needs to be HTML in order for this to work.

Out of curiosity, which DBMS are you accessing?


Thank you for using Focal Point!

Chuck Wolff - Focal Point Moderator
WebFOCUS 7x and 8x, Windows, Linux All output Formats
 
Posts: 2128 | Location: Customer Support | Registered: April 12, 2005Report This Post
Member
posted Hide Post
Thanks Chuck.

I am connecting to Teradata.

I am able to see it now.

Thanks again.


WEBFOCUS - 8202
OS - Windows
Output - PDF, Excel, HTML, txt.
 
Posts: 9 | Registered: July 27, 2020Report 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     [CLOSED] View generated sql query using view source

Copyright © 1996-2020 Information Builders