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     Batch JAVA program executing .fex file

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Batch JAVA program executing .fex file
 Login/Join
 
Member
posted
I need to know how to execute a .fex report from a Batch JAVA application (not web). I know this can be done through shell script on Unix, we would like to execute directly from JAVA. Thoughts???


7.1.6.
AIX Unix.
HTML, EXCEL, and PDF output
 
Posts: 3 | Registered: March 20, 2008Report This Post
Gold member
posted Hide Post
try something like this which calls a bat routine which runs a focexec

String cmd = "cmd.exe /C c:\\temp\\test.bat";

Process proc;
proc = Runtime.getRuntime().exec(cmd);

StreamDumper stdin = new StreamDumper proc.getInputStream(), false);
StreamDumper stderr = new StreamDumper(proc.getErrorStream(), true);

stdin.start();
stderr.start();


in the bat you could have a dos call

-DOS CALL TEST


WF 7.6.10 /IIS 6/ JBoss Enterprise 4.3
Windows XP SP 2/Windows 2003 Server
MVS 7.3.3
 
Posts: 76 | Location: Hartford, CT | Registered: August 30, 2005Report This Post
Gold member
posted Hide Post
here is another way you could try it

import java.io.*;
import java.util.*;
import java.lang.Object;
import java.net.*;

public class Program
{
public static void main(String s[])
{
System.out.println("Hello this programm defines about how to call a servlet with a java application ");
try{


URL servlet = new URL("http://localhost:8080/ibi_apps/WFSerlvet?IBIF_ex=carinst");
URLConnection conn=servlet.openConnection();
conn.setDoOutput(true);
InputStreamReader isr=new InputStreamReader(conn.getInputStream());
BufferedReader br = new BufferedReader(isr);
String str;
System.out.println("Source code is" ); str=br.readLine();
System.out.println(str);


}
catch(IOException e)
{
System.out.println("exception is" +e);
}

}
}


WF 7.6.10 /IIS 6/ JBoss Enterprise 4.3
Windows XP SP 2/Windows 2003 Server
MVS 7.3.3
 
Posts: 76 | Location: Hartford, CT | Registered: August 30, 2005Report This Post
Member
posted Hide Post
Keep in mind this is running on Unix. I need to be able to execute this from a Batch JAVA application and not Web. No interaction with a web Server.


7.1.6.
AIX Unix.
HTML, EXCEL, and PDF output
 
Posts: 3 | Registered: March 20, 2008Report This Post
Virtuoso
posted Hide Post
Is there a WF server installed on this sames box where the java batch program runs?


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report This Post
Member
posted Hide Post
It would be on the same newtork, but most likely not the same server.


7.1.6.
AIX Unix.
HTML, EXCEL, and PDF output
 
Posts: 3 | Registered: March 20, 2008Report This Post
Member
posted Hide Post
Hello ,
Try to expoze the fex procedure like a webservice and after make a call from java .
The webserices is not platform depending .

Regards,
Val

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


WF 7.6.2 , iWay 5.5 , Sun Unix , Windows XP , .NET , Oracle , SQL Server and more
 
Posts: 24 | Registered: December 05, 2007Report This Post
Virtuoso
posted Hide Post
It isn't platform dependendent but it IS License dependent. Enabling your procedures as web services requires and additional license.

If there is no interaction with a web server and the java program exists on a separate box from your WF server, you're going to be pretty hard pressed to find a solution.

The main question is, How are you running WebFOCUS without a web server?

The rhetorical answer is there probably IS a webserver in there. You just may not have the info you need to access it or is web/IP access explicitly blocked on this box?


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report 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     Batch JAVA program executing .fex file

Copyright © 1996-2020 Information Builders