Integrate Crystal Reports with Spring MVC and Hibernate

Hi all,
having successfully used the JRC version 11.8.4.1094 in a Java environment with:
1)JBoss 4.2.3,
2)Oracle 11,
3)EJB 2,
4)Crystal Reports 2008,
I would like to integrate Crystal Reports into my existing spring MVC and hibernate web app using:
1)CRJ version 12.2.209,
2)JBoss 5.1,
3)Oracle 11,
4)EJB 3,
5)Crystal Reports 2008,
reusing code integration. I used ReportExportControl and I produced the PDF directly.
The error occurs when returning from EJB, into Delegate, and is the following:
09:36:23,046 WARN  [InterceptorsFactory] EJBTHREE-1246: Do not use InterceptorsFactory with a ManagedObjectAdvisor, InterceptorRegistry should be used via the bean container
09:36:23,062 WARN  [InterceptorsFactory] EJBTHREE-1246: Do not use InterceptorsFactory with a ManagedObjectAdvisor, InterceptorRegistry should be used via the bean container
09:38:03,062 ERROR [[dispatcher]] Servlet.service() for servlet dispatcher threw exception
java.lang.InstantiationException: com.crystaldecisions.sdk.occa.report.exportoptions.ReportExportFormat
     at java.lang.Class.newInstance0(Class.java:340)
     at java.lang.Class.newInstance(Class.java:308)
     at org.jboss.serial.classmetamodel.ClassMetaData.newInstance(ClassMetaData.java:334)
     at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:239)
     at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
     at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
     at org.jboss.serial.objectmetamodel.DataContainer$DataContainerInput.readObject(DataContainer.java:845)
     at org.jboss.serial.persister.RegularObjectPersister.readSlotWithFields(RegularObjectPersister.java:353)
     at org.jboss.serial.persister.RegularObjectPersister.defaultRead(RegularObjectPersister.java:273)
     at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:241)
     at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
     at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
     at org.jboss.serial.objectmetamodel.DataContainer$DataContainerInput.readObject(DataContainer.java:845)
     at org.jboss.serial.persister.RegularObjectPersister.readSlotWithFields(RegularObjectPersister.java:353)
     at org.jboss.serial.persister.RegularObjectPersister.defaultRead(RegularObjectPersister.java:273)
     at org.jboss.serial.persister.RegularObjectPersister.readData(RegularObjectPersister.java:241)
     at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.readObjectDescriptionFromStreaming(ObjectDescriptorFactory.java:412)
     at org.jboss.serial.objectmetamodel.ObjectDescriptorFactory.objectFromDescription(ObjectDescriptorFactory.java:82)
     at org.jboss.serial.objectmetamodel.DataContainer$DataContainerInput.readObject(DataContainer.java:845)
     at org.jboss.serial.io.MarshalledObjectForLocalCalls.get(MarshalledObjectForLocalCalls.java:60)
     at org.jboss.ejb3.remoting.IsLocalInterceptor.invokeLocal(IsLocalInterceptor.java:101)
     at org.jboss.ejb3.remoting.IsLocalInterceptor.invoke(IsLocalInterceptor.java:72)
     at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)
     at org.jboss.aspects.remoting.PojiProxy.invoke(PojiProxy.java:62)
     at $Proxy286.invoke(Unknown Source)
     at org.jboss.ejb3.proxy.impl.handler.session.SessionProxyInvocationHandlerBase.invoke(SessionProxyInvocationHandlerBase.java:207)
     at org.jboss.ejb3.proxy.impl.handler.session.SessionProxyInvocationHandlerBase.invoke(SessionProxyInvocationHandlerBase.java:164)
     at $Proxy284.getXXXX(Unknown Source)
     at xx.xxx.xxxxxx.spring.manager.report.ReportManagerImpl.getXXXX(ReportManagerImpl.java:26)
     at xxx.xxxx.springprova.WelcomeController.handleRequestInternal(WelcomeController.java:70)
     at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
     at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
     at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:790)
     at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
     at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
     at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
     at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
     at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
     at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
     at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
     at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
     at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
     at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
     at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
     at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
     at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
     at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
     at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
     at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
     at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
     at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
     at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
     at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
     at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
     at java.lang.Thread.run(Thread.java:662)
Have an idea, please?
Thank you.

You'll need to install the Crystal .NET that comes with VS 2005. You then install Crystal XI R2 over the top and not only will Crystal be integrated with the IDE, it should use the updated assemblies from R2.
-Dell
- A computer only does what you told it to, not what you thought you told it to!</p>

Similar Messages

  • How to integrate Crystal Report  with oracle JDeveloper 11g

    Hi,
    How to integrate Crystal Report  with oracle JDeveloper 11g
    Regards ,
    Amol

    I dont think that you can integrate Crystal Reports with JDevelpoer but you can use runtime libraries to your project to get crystal report functionality
    To know more please go through supported platforms
    [Supported Platforms|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/504d0204-681e-2b10-2381-853d88974cfc]
    Regards,
    Tej

  • Integrate Crystal Reports XI Release 2 and VS2005 IDE

    <p>Hi,</p><p>How can i integrate Crystal Reports XI R2 is directly into the Visual Studio 2005 development environments. So i can host my report in either a Web or Windows application with one of the Crystal Reports viewer controls, or use the extensive API to interact with the report programmatically at runtime. </p><p>My current setup is:</p><blockquote><p>Crystal Reports XI Release 2.</p></blockquote><blockquote><p>Visual Studio 2005 Professional (I did not install the Crystal Reports .Net shipped with VS 2005.)</p><p>SQ Server 2000.</p><p>&#160;</p></blockquote><p>Thanks Please help.</p>

    You'll need to install the Crystal .NET that comes with VS 2005. You then install Crystal XI R2 over the top and not only will Crystal be integrated with the IDE, it should use the updated assemblies from R2.
    -Dell
    - A computer only does what you told it to, not what you thought you told it to!</p>

  • Can anyone let me know how to integrate crystal reports with bi 7?

    HI all,
    Can anyone pls let me know the steps involved in integrating crystal reports with bi 7?
    thanks
    Pooja

    1.install BO client tools
    2. install crystal reports
    3.install sap integration kit
    once you install in above sequence you will be able to pull data from BW system.

  • Integrate Crystal Reports version 11.5 and Visual FoxPro

    Post Author: landc50
    CA Forum: General
    I have developed several softwares in Visual FoxPro while using Crystal Reports Version 7 as the major reporting tool.   It was easy to invoike Crystal reports from my applications, simply by adding the Crystal OCX onto the VFP form. 
    Now --- I have added the ActiveXReportViewer from version 11.5 onto my VFP form.    Looks ok but it I am not sure how to invoke the reports in Maximized mode.   Seems like it will only show the report the same size as the object I placed on my VFP form.
    I need to know how to do this yesterday.   I must implement a new system and I do not want to revert back to Crystal reports version 7.   Any help would be appreciated. 

    Post Author: The Donger
    CA Forum: General
    Hi,
    I would recommend you have an empty form and drop the viewer on that form.  Set the form's state to Maximize. 
    Good luck,
    Brian

  • Add Image to Jasper Report with Struts 2 and Hibernate

    Hi I want to add image to jasper report[pdf] in the environment of Struts 2 framework and hibernate. I am trying
    this for last couple of days, but i am unable to get the work done. if any body know the steps to add image to
    jasper reports, please help me or if u have any tutorials please let me know. I am using iReport-nb-3.5.0 to generate jasper files.
    Thanks in advance

    Finally i found a way to add image to jasper report. It is pretty simple, just give the exact image location to the image expression. In your web application, the image location may vary so, dynamically set the image location from your model class. Also, make sure that your lib folder contains itext-1.3.1.jar. If your lib folder contains itext-1.3.1.jar and iText-2.1.3.jar u will get like: java.lang.NoSuchMethodError: com.lowagie.text.Image.plainWidth()F
    So remove the iText-2.1.3.jar and keep only itext-1.3.1.jar, try this will work

  • Integrating crystal report with swing application

    Hi,
    Any body knows how to integrate crystal reports with swings?
    I'm posting this after a painful search in the net/forum.Any idea
    will be greatly apprecited.
    thanx.
    regards,
    jmos

    The best place to pick up sample code is straight from the horses mouth. [url http://www.businessobjects.com/products/dev_zone/java/default.asp?ref=devzone_main] Crystal java zone

  • Integrating Crystal Report with JSP

    Could any one send me a sample code how to integrate crystal Report
    with JSP. If so it will be a grade help for my project work.
    Thanks Rasika

    The best place to pick up sample code is straight from the horses mouth. [url http://www.businessobjects.com/products/dev_zone/java/default.asp?ref=devzone_main] Crystal java zone

  • How to integrate Crystal Report Server and J2EE platform

    Hi,
    It's my first time using Crystal Report, so I don't know exactly how I should start...
    As what i've searched around, there is a method of generating crystal report from a JSP file. By this way, everything will be handled within the application server.
    But in my project, we intend to leave the part of handling and generating report to another server, i.e. there will be 2 servers: application & report. Anyone experienced with this can guide me through? By splitting into 2 servers, that means I will need to have the Crystal Report Server right? And if doing so, from the application, how do I call the Crystal Report server?
    Thanks for viewing...

    You can use [Crystal Reports for Eclipse|Crystal Reports for Eclipse 2.0 Release Update 8 is Now Available!; to do exactly this. It comes with an example application for displaying reports using the CR Web Report Viewer. It's EXTREMELY easy to use and even to integrate in your existing web app. If you're using Eclipse and have the CR4E plugin installed, you can go to File > New > Crystal Reports and select Crystal Reports Web Project. This will create the CR server application for you. You can also right click on an existing web app and have Crystal Reports integrated directly into your existing app.
    To do this, just right click on your web app and go to Project Properties. Then, go to Project Facets, check the box next to Crystal Reports, click Apply and then OK. It will copy all of the necessary runtimes into your lib folder and will even update your web.xml to include the stuff needed for CR. On the left, you should see Crystal Reports File Versions. Click on that and you should see the version of Crystal that was just installed into your web app along with all of the files that were copied or modified.
    You could probably then create a report viewer in your other app (maybe an iframe?) that includes a link to the report in the CR Web App.
    If you need more assistance with this, let me know. I'd be glad to help out as I've already played with something similar to this.

  • Difference between Crystal Report with VS2010 and Crystal Report Professional Version

    Dear Experts,
    We want to know the difference between Crystal Report Version with VS 2010 and Crystal Report Profesional Version.
    And from where we should buy it provide the link.
    Thanking you,
    Miral Shah

    If you are looking for difference in features, see this.
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/60df293e-41e8-2e10-9293-fa4beeb40a99?QuickLink=index&overridelayout=true&52772263221521
    You could design your report with any one of CR 2008/2011/2013 and still could use in the app with 13 version references.
    Here is the licensing info. http://scn.sap.com/docs/DOC-21575
    - Bhushan
    Senior Engineer
    SAP Active Global Support
    Follow us on Twitter
    Got Enhancement ideas? Try the SAP Idea Place
    Getting started and moving ahead with Crystal Reports .NET applications.

  • Connecting Crystal reports with dashboards and passing parameters

    Hi ,
    Can anyone have any document on Connecting Crystal reports with dashboards and passing parameters.
    I would appreciate for this.
    Thank You.

    Hi Ganesh,
    You can refer the following links for connecting Crystal reports with dashboards:
    Dashboard integration in Crystal Reports using flash variables | Clariba Blog
    https://websmp102.sapag.de/~sapidp/011000358700001426732009E/Xcelsius_EmbeddingInCR2008.pdf
    http://events.asug.com/2012BOUC/0315_Integrating_SAP_Dashboards_into_SAP_Crystal_Reports.pdf
    Regards,
    Renu

  • Integrate Crystal Reports 2008 in Lotus Notes 8.x

    We allready use Crystal Reports 2008 with Lotus Notes 8.x trough NotesSQL 8.5. This works fine.
    Now we want integrate Crystal Reports 2008 directly in Lotus Notes 8.x. so that the user can start reports directly from his Lotus Notes Application. Of course, data has to be retrieved in realtime (not with data stored in the report) and he should be able to pass parameters from a lotus notes form.
    All informations we found are quit old (Crystal Reports 8.5 and Lotus Notes R5). Does anyone has an idea how to start and where to find new documentations? Is there maybe even a sample application availabl?
    Any help is welcome!

    Hello Alain, I have the same troubles. I have some databases with Crystal Reports 9. But no solution for Crystal Report 2008.
    Which dll's are needed?

  • How to use crystal report with php

    Hello every body
    can any body know how to use crystal report with php any helping material, code or tutorial for my problem ill be very thankful for helping me
    farooq

    Hello sir
    i am sudeep and i need to deploy crstal reports in php
    i want to integrate it in sugar crm (open source project(
    can u plz tell me how to do it
    i have written this code
    <?php
    //echo phpinfo();exit;
    $ObjectFactory= New COM("CrystalReports11.ObjectFactory.1");
    $crapp = $ObjectFactory->CreateObject("CrystalDesignRunTime.Application");
    //$crapp = new COM("CrystalRuntime.Application.10");
    $reportToRun="C:\Report4.rpt";
    $creport = $crapp->OpenReport($reportToRun, 1);
    //reportToRun=full path to *.rpt file
    $creport->Database->Tables->
    Item(1)->ConnectionProperties['User ID'] = $user;
    $creport->Database->Tables->
    Item(1)->ConnectionProperties['Password'] = $pass;
    //fomatType = integer 22=xls, 31=pdf etc
    $creport->ExportOptions->FormatType = $formatType;
    //type 1 is to output to a file I think 2 is email
    $creport->ExportOptions->DestinationType = 1;
    //location = full path to report output file
    $creport->ExportOptions->DiskFileName = $location;
    $creport->DiscardSavedData();
    $creport->Export(False);
    ?>
    thanks in advance

  • Unable to integrate Oracle Reports with Express--(To oracle Team also)

    Hi
    Unable to integrate Oracle Reports with Express. While defining
    the Express database connection using the olap connection editor
    iam getting the following error "Error locating the XCONEDIT.INI
    file. Try re-installing the software".
    what should be done?
    Atleat,If anybody has successfully connected to Express via
    Reports6i. Kindly give the details like what softwares to be
    installed in what HOME? and also other steps involved in the
    process.
    YOur help !!!
    kindly respond...(Oracle Team do respond with something)
    with rgds

    hello,
    check out the notes
    Note:112542.1
    Note:167049.1
    on oracle metalink for further information.
    if you still have issues, please contact oracle support services
    for furhter assistence.
    regards,
    the oracle reports team --pw                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • JRC bug: apostrophe in string parameter passed to Crystal Report with Command datasource to SQL Server

    Post Author: nl11087
    CA Forum: JAVA
    A single quote/apostrophe in string parameter passed to a Crystal Report with Command datasource connecting to a SQL Server database, using sqljdbc driver does not escape the special character correctly. When doing a preview in the Crystal Reports IDE it allows you to escape the input parameter as expected and work correctly, but through the JRC component it fails. For string parameters without special sql server characters I experience no problems at all. When replacing the Command with a direct table there is also no problem.
    Reproduction:
    1. create a database db1, create a table table1 with a String type column col1.
    2. Create new report Report1.rpt, create a connection to above, Add Command using 'SELECT col1, col2, col3 FROM table1 WHERE col1 = '{?Par1}' . Add a parameter field Par1 : String
    3. In your java stand alone application using JRC add the parameter Par1 with a value "Jon Doe's Value" containing a single apostrophe. Export to PDF. (I also tried MSWord and this failed too, similar behavior). Additionally, in another test try to replaceAll("'","''") to escape it, preventing the code to break, but now it does not retrieve the expected row anymore and you end up with an empty report.
    Exception StackTrace:
    com.crystaldecisions.reports.exportinterface.exceptions.ExportException: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.formatter.a.c.if(Unknown Source)
    at com.crystaldecisions.reports.formatter.a.c.a(Unknown Source)
    at com.businessobjects.reports.sdk.b.b.int(Unknown Source)
    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.x.a(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.q.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.dd.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.reports.sdk.PrintOutputController.export(Unknown Source)
    Caused by: com.crystaldecisions.reports.formatter.formatter.c: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.formatter.formatter.objectformatter.bv.<init>(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.objectformatter.bv.if(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.e.l.<init>(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.e.p.<init>(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.e.p.a(Unknown Source)
    at com.crystaldecisions.reports.formatter.a.c.a(Unknown Source)
    ... 17 more
    Caused by: com.crystaldecisions.reports.dataengine.be: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.dataengine.n.else(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.nr(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.bn(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.bp(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.else(Unknown Source)
    at com.crystaldecisions.reports.dataengine.s.a(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.a(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.aa(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.<init>(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.<init>(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.<init>(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.a(Unknown Source)
    ... 23 more
    Caused by: com.crystaldecisions.reports.reportdefinition.datainterface.n: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.reportdefinition.datainterface.p.a(Unknown Source)
    ... 35 more
    Caused by: com.crystaldecisions.reports.queryengine.driverImpl.m: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.queryengine.driverImpl.o.eC(Unknown Source)
    at com.crystaldecisions.reports.queryengine.driverImpl.o.if(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ap.ea(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ap.h(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ap.dV(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ax.if(Unknown Source)
    at com.crystaldecisions.reports.queryengine.bc.if(Unknown Source)
    at com.crystaldecisions.reports.queryengine.bc.do(Unknown Source)
    at com.crystaldecisions.reports.queryengine.bc.do(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ae.cy(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ae.cz(Unknown Source)
    at com.crystaldecisions.reports.queryengine.b1.bc(Unknown Source)
    ... 36 more
    Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near 's'.
    at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
    at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement$StatementExecutionRequest.executeStatement(Unknown Source)
    at com.microsoft.sqlserver.jdbc.CancelableRequest.execute(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeRequest(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement.execute(Unknown Source)
    ... 48 more
    - JRCAgent3 detected an exception: An error occured while exporting the report
    at com.businessobjects.reports.sdk.b.b.int(Unknown Source)
    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.x.a(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.q.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.dd.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.reports.sdk.PrintOutputController.export(Unknown Source)

    Post Author: nl11087
    CA Forum: JAVA
    A single quote/apostrophe in string parameter passed to a Crystal Report with Command datasource connecting to a SQL Server database, using sqljdbc driver does not escape the special character correctly. When doing a preview in the Crystal Reports IDE it allows you to escape the input parameter as expected and work correctly, but through the JRC component it fails. For string parameters without special sql server characters I experience no problems at all. When replacing the Command with a direct table there is also no problem.
    Reproduction:
    1. create a database db1, create a table table1 with a String type column col1.
    2. Create new report Report1.rpt, create a connection to above, Add Command using 'SELECT col1, col2, col3 FROM table1 WHERE col1 = '{?Par1}' . Add a parameter field Par1 : String
    3. In your java stand alone application using JRC add the parameter Par1 with a value "Jon Doe's Value" containing a single apostrophe. Export to PDF. (I also tried MSWord and this failed too, similar behavior). Additionally, in another test try to replaceAll("'","''") to escape it, preventing the code to break, but now it does not retrieve the expected row anymore and you end up with an empty report.
    Exception StackTrace:
    com.crystaldecisions.reports.exportinterface.exceptions.ExportException: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.formatter.a.c.if(Unknown Source)
    at com.crystaldecisions.reports.formatter.a.c.a(Unknown Source)
    at com.businessobjects.reports.sdk.b.b.int(Unknown Source)
    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.x.a(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.q.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.dd.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.reports.sdk.PrintOutputController.export(Unknown Source)
    Caused by: com.crystaldecisions.reports.formatter.formatter.c: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.formatter.formatter.objectformatter.bv.<init>(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.objectformatter.bv.if(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.e.l.<init>(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.e.p.<init>(Unknown Source)
    at com.crystaldecisions.reports.formatter.formatter.e.p.a(Unknown Source)
    at com.crystaldecisions.reports.formatter.a.c.a(Unknown Source)
    ... 17 more
    Caused by: com.crystaldecisions.reports.dataengine.be: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.dataengine.n.else(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.nr(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.bn(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.bp(Unknown Source)
    at com.crystaldecisions.reports.dataengine.n.else(Unknown Source)
    at com.crystaldecisions.reports.dataengine.s.a(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.a(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.aa(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.<init>(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.<init>(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.<init>(Unknown Source)
    at com.crystaldecisions.reports.dataengine.bk.a(Unknown Source)
    ... 23 more
    Caused by: com.crystaldecisions.reports.reportdefinition.datainterface.n: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.reportdefinition.datainterface.p.a(Unknown Source)
    ... 35 more
    Caused by: com.crystaldecisions.reports.queryengine.driverImpl.m: JDBC Error: Incorrect syntax near 's'.
    at com.crystaldecisions.reports.queryengine.driverImpl.o.eC(Unknown Source)
    at com.crystaldecisions.reports.queryengine.driverImpl.o.if(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ap.ea(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ap.h(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ap.dV(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ax.if(Unknown Source)
    at com.crystaldecisions.reports.queryengine.bc.if(Unknown Source)
    at com.crystaldecisions.reports.queryengine.bc.do(Unknown Source)
    at com.crystaldecisions.reports.queryengine.bc.do(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ae.cy(Unknown Source)
    at com.crystaldecisions.reports.queryengine.ae.cz(Unknown Source)
    at com.crystaldecisions.reports.queryengine.b1.bc(Unknown Source)
    ... 36 more
    Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near 's'.
    at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(Unknown Source)
    at com.microsoft.sqlserver.jdbc.IOBuffer.processPackets(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement$StatementExecutionRequest.executeStatement(Unknown Source)
    at com.microsoft.sqlserver.jdbc.CancelableRequest.execute(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeRequest(Unknown Source)
    at com.microsoft.sqlserver.jdbc.SQLServerStatement.execute(Unknown Source)
    ... 48 more
    - JRCAgent3 detected an exception: An error occured while exporting the report
    at com.businessobjects.reports.sdk.b.b.int(Unknown Source)
    at com.businessobjects.reports.sdk.JRCCommunicationAdapter.request(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.x.a(Unknown Source)
    at com.crystaldecisions.proxy.remoteagent.q.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.dd.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.ReportSource.a(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.sdk.occa.report.application.PrintOutputController.export(Unknown Source)
    at com.crystaldecisions.reports.sdk.PrintOutputController.export(Unknown Source)

Maybe you are looking for

  • Dbms_lob package

    i am using this method dbms_lob.getlength(column name) from table name; as far as i know this column can be a clob column or blob column or bfile column i have a row in these columns inserted via java at the sql prompt i just want to see the length o

  • How do I sync an album that downloaded into two albums into one album?

    I downloaded the album La Musica No se Toca onto my windows computer and synched it to my ipad. The problem is the first song by the same title appears as its own album. Of course, I want to hear the song with the rest of the album. I've tried using

  • I am unable to email video.It goes to unsent items says I need to mail password . all emails otherwise come and go?

    I am unable to send video via email. all other emails come and go without a problem. says I need to set password?

  • App world

    Always have an error code 30702 when try to use my app world,I want to know the solution

  • GG not starting

    Hi, GG 11.2 Replicat not starting (ABENDED immediatly), no error found in logs. Below some logs. Can you help ? Thanks ========================================================================== more ggserr.log 2013-07-18 09:52:14  INFO    OGG-00975