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.
Starting in SQL Server 2016, you have the ability to Format Query Results as JSON. With the ability in SQL Server2016 and later, you can create milti-level JSON:
I know that IBI has ON TABLE HOLD FORMAT JSON, however it only has the ability to show data in a single level (please correct me if I'm wrong).
So, my question is, has anyone been able to do a SQL Passthru query to retrieve JSON output?This message has been edited. Last edited by: FP Mod Chuck,
Hallway
Prod: 8202M1
Test: 8202M4
Repository:
OS:
Outputs:
Posts: 608 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015
i did similar json format from SQL DB before IBI release the JSON Format. I created Stored procedure to return the json format and created synonym in webfocus for that stored procedure. I created procedure with PCHOLD format WP . Then in the HTML Page AJAX, called the procedure. Sometimes i used custom java script parser to manipulate the json.
Originally posted by Frans: is your goal to retrieve the JSON output, or pass the JSON with WebFOCUS to a client?
I am wanting to pass the JSON to a webpage into a JS charting library. So, basically using WebFOCUS like an API endpoint. I am currently using the FORMAT JSON output in WebFOCUS, but I have to do a lot of JavaScript Array and Object manipulation to get it into the proper format to pass to the charting engine. I could write a query in SQL Server that would give me the needed format. It would simplify the process if it were possible for a "SQL Passthru" to actually work like a true SQL Passthru.
Hallway
Prod: 8202M1
Test: 8202M4
Repository:
OS:
Outputs:
Posts: 608 | Location: Salt Lake City, UT, USA | Registered: November 18, 2015
I have done similar in WF 8201 for Year calendar and Kendo Grid.
1. Create a Stored procedure that should return your json. 2. In webfocus Create a procedure and choose Format WP. 3. Use the HTML Form to Store it as variable. 4. You can call this Procedure in the AJAX. 5. The result format will be in JSON .
TABLE FILE SP_REMINDER_DETAIL_SELECT_JSON_FOR_CALENDAR
PRINT
SP_REMINDER_DETAIL_SELECT_JSON_FOR_CALENDAR.ANSWERSET1.VALIDJSON AS ''
ON TABLE SET PAGE-NUM NOLEAD
ON TABLE SET ASNAMES ON
ON TABLE NOTOTAL
ON TABLE HOLD AS REMINDER_DETAILS FORMAT WP
ON TABLE SET HTMLCSS ON
ON TABLE SET STYLE *
INCLUDE = IBFS:/EDA/EDASERVE/_EDAHOME/ETC/warm.sty,
$
TYPE=REPORT,
COLUMN=N1,
$
ENDSTYLE
END
-RUN
SET HTMLFORMTYPE=TXT
-HTMLFORM BEGIN
!IBI.FIL.REMINDER_DETAILS;
-HTMLFORM END