I looked at a product called CrystalClear, I tested it a year ago, and it
looked very nice...  Its www.inetsoftware.de It would allow me to place my
crystal report files, in the ifs and run it nativly..

Here is a small piece of code I wrote a while ago to test it..

The only feature, I'm waiting for, before I buy it is..  Specified order
grouping in a crosstab... They have it, in a standard report... But I use it
a lot in crosstabs...  

Tim



CL--
 RUNJVA     CLASS(reportwrapper) +                              
          PARM('-R/java/usersheet.rpt' +                    
          '-O/java/rwtest.pdf' '-Xpdf' '-pACCT' +           
          '-pMARK') +                                        
          CLASSPATH('/Java:/Java/CrystalClear.jar:/QJ+      
          AVA:/QIBM/ProdData/HTTP/Public/jt400/lib/jt+      
          400.jar')                                         
                                                                          
                                                                          


Java---
import com.inet.report.*;
import java.io.FileOutputStream;

public class reportwrapper {
 
    public static void main(String[] args) {
        try {

                String reportname      = null;
                String outputfilename  = null;
                String exportformat    = null;
                String parameter       = null;

                int k = 0;
                while ( args.length > k )
                {
                        if ( args[k].startsWith("-R") )
                                reportname = args[k].substring(2);
                        if ( args[k].startsWith("-O") )
                                outputfilename = args[k].substring(2);
                        if ( args[k].startsWith("-X") )
                                exportformat = args[k].substring(2);

                        k++;    
                }
           System.out.println("Report Name|"+reportname);
           System.out.println("Output filename|"+outputfilename);
           System.out.println("Export Mode|"+exportformat);
                
            Engine e = new Engine(exportformat);

        
            
                                                // set the report file
            e.setReportFile("file:"+reportname);

                                                                // at this
point you can change the
                                                                // default
values from the rpt file
                                                                // for
example:

              e.setDll("pdsdb2.dll");

              
// we need read the report parameters here, because we had to create the 'e'
class first...           
                k = 0;
                int p = 0;
                while ( args.length > k )
                {
                        if ( args[k].startsWith("-p") )  {
                                       parameter = args[k].substring(2);
           System.out.println("Parameter ("+p+") ==>"+parameter);
                       e.setPrompt(parameter, p);
                       p++;                                             
                        }
                        k++;    
                }

              
              
//              e.setUser("TIMH");
//              e.setPassword("xxxxxxx");
//              e.setPrompt("TEC2748", 0);
//              e.setHost("jdbc:as400://MYAS400"); 
//              e.setSchema("");
//              e.setPrompt("['promptval2']", 1);
//              e.setPrompt("promptval3", 2);
//              e.setPrompt("Date(1899,11,31)", 3);
//              e.setPrompt("Date(3000,11,31)", 4);

            
                                                                // now start
the transformation
            e.execute();

                                                                // open the
output file and save the data
            FileOutputStream pdfFile = new FileOutputStream(outputfilename);
            int pageCount = e.getPageCount();
            byte[] b = e.getPageData(0);
            
            pdfFile.write(b);
            pdfFile.close();
            
            System.out.println("Wrote pages: "+pageCount);

        } catch (Throwable t ) { 
            t.printStackTrace();
        }
        System.exit(0);
    }
}

-----Original Message-----
From: java400-l-bounces@xxxxxxxxxxxx [mailto:java400-l-bounces@xxxxxxxxxxxx]
On Behalf Of Jon Paris
Sent: Tuesday, November 29, 2005 10:50 AM
To: Java List
Subject: Java for Batch and Reporting

Any of you have any experience of coding heavy-duty batch update/reporting
functions in Java on iSeries?

I'm particularly interested in the performance aspects and if anyone has any
exposure to the Crystal or other reporting software.

Jon Paris
Partner400

www.Partner400.com
www.RPGWorld.com

--
This is the Java Programming on and around the iSeries / AS400 (JAVA400-L)
mailing list To post a message email: JAVA400-L@xxxxxxxxxxxx To subscribe,
unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/java400-l
or email: JAVA400-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/java400-l.


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.