Retrieving Reports from Cache

10gAS 9.0.4.1
Reports 9.0.2.0.3
First Issue:
I am trying to reuse reports from cache. I have caching turned on in my rep_<server>.conf file, and the following entry in my cgicmd.dat file:
rep17: report=<report name>.jsp <parameter>=%1 desformat=pdf destype=cache server=<report server> paramform=no ssoconn=<rad> tolerance=30
Each time I run the report, a new copy is generated in the cache directory. The report returned to me is the new copy. Should the report server not retrieve an earlier copy of the report as long as it was generated within the last 30 minutes?
Second Issue:
When I run the report URL in Internet Explorer (version 6.0.2800.1106CO), 2 copies of the report output are created in cache. When using Netscape (version 7.2), only 1 copy of the report output is generated in cache. What are the issues with IE that cause two copies of the report output to be generated?

Hi Birol,
Can you please tell me is the content you have used in that "BAPI_DOCUMENT_CHECKOUTVIEWX programme"????
Regards
Harshavardhan.G

Similar Messages

  • Retrieving documents from cache server using Bapi_Document_Checkoutviewx

    Hello,
    how can I retrieve the documents from cache server instead from content server, which are stored in SAP R/3 system.
    I use the bapi "BAPI_DOCUMENT_CHECKOUTVIEWX" in a Rfc-Client Programm to retrieve the documents. This BAPI retrieves the documents allways from content server and don't use the existent cache server.
    Thanks for any help!
    Birol

    Hi Birol,
    Can you please tell me is the content you have used in that "BAPI_DOCUMENT_CHECKOUTVIEWX programme"????
    Regards
    Harshavardhan.G

  • C# retrieve report from SAP Crystal Server

    I have installed SAP Crystal Server on a Windows 2012 Server machine. The installation looks fine. I can run the Central Management Console and everything appears to be up and running.
    I have a Windows application running on my local machine and all I want to do is run a report.
    myRCDoc = new ReportClientDocument();
    myRCDoc.ReportAppServer = _server;
    object path = reportName;
    myRCDoc.Open(ref path, 0);
    I get the following error:
    An unhandled exception of type 'System.Runtime.InteropServices.COMException' occurred in Billings.exe
    Additional information: Failed to connect to server "ENTBSQ01".
    How do I make the server reachable from my windows code?

    Thanks Dell!
    I'm currently not logging into the CMS.
    I'm not clear when you ask "working with reports from CRS"? 
    The *.rpt files are indeed stored on the server.  My windows app simply calls ReportClientDocument.Open to get the report.  I'm assuming that means I am indeed working with reports from CRS.
    I'll try to logging in part first and then move to checking the SDK.
    Thanks again!
    -Terry

  • Clearing the report from cache....

    Hello all,,,
    In my project iam using crystsal report for eclipse to generate reports.
    Iam using a .jsp page to call my report.(which i got it from the examples of CRE).
    The name of my jsp page is poi.jsp
    The name of my Crystal report is CrystalReport2.rpt
    My problem is this....
    when i run the report first time i can see my poi.jsp page and user can submit
    the parameter and based on the users parameter the report is generated..(ITs working absoultely fine)but when the user runs the report again, its not showing the parameter page (i.e user cannot see poi.jsp) rather its showing the old generated report.
    When i tried using session.invalidate and session.removeAttribute it was showing me the poi.jsp page but the problem is when the user clicks on the print icon or any icon on the report its just showing the poi.jsp page...
    When the user closes the report or when the clicks on the button to generate the report it should show the parameter page (poi.jsp).how can i solve this problem???
    the code what iam using is as follows..( got it from the examples of CRE - database login )
              response.setHeader("Cache-Control","no-cache");
              response.setHeader("Pragma","no-cache");
              response.setDateHeader("Expires",-1);
              response.setHeader("Cache-Control","no-store");
              Object reportSource = session.getAttribute("reportSource");
            if (reportSource == null )
                String report = "CrystalReport2.rpt";
                ReportClientDocument reportClientDoc = new ReportClientDocument();
                reportClientDoc.open(report, 0);
                reportSource = reportClientDoc.getReportSource();
                session.setAttribute("reportSource", reportSource);
            ConnectionInfos connInfos = new ConnectionInfos();
            IConnectionInfo connInfo1 = new ConnectionInfo();         
            connInfo1.setUserName("CS22USER");
            connInfo1.setPassword("CS22USER");
            connInfos.add(connInfo1);
            CrystalReportViewer viewer = new CrystalReportViewer();
            viewer.setReportSource(reportSource);          
              viewer.setEnableLogonPrompt(false);
            viewer.setDatabaseLogonInfos(connInfos);
            if (session.getAttribute("refreshed") == null)                  
                 viewer.refresh();               
                 session.setAttribute("refreshed", "true");           
                 //response.sendRedirect("Test.jsp");
                  //session.removeAttribute("refreshed");    
                  //session.invalidate();
                  //session.removeAttribute("refreshed");       
            viewer.setOwnPage(true);
            viewer.processHttpRequest(request, response, getServletConfig().getServletContext(), null);                     
            //session.invalidate();

    CrystalReportViewer viewer = new CrystalReportViewer();
    viewer.setReportSource(reportSource);
         viewer.setReportSource(reportSource);
         viewer.setHasRefreshButton(true);
         viewer.setOwnPage(true);
         viewer.setOwnForm(true);
         viewer.setHasExportButton(true);
         viewer.setZoomFactor(100);
         viewer.setPrintMode(CrPrintMode.ACTIVEX);
        viewer.setParameterFields(fields);
    viewer.setEnableParameterPrompt(true); --this line will prompt

  • Help neede very very urgently ... to clear the report from Cache.....

    Hello all,,,
    In my project iam using crystsal report for eclipse to generate reports.
    Iam using a .jsp page to call my report.(which i got it from the examples of CRE).
    The name of my jsp page is poi.jsp
    The name of my Crystal report is CrystalReport2.rpt
    My problem is this....
    when i run the report first time i can see my poi.jsp page and user can submit
    the parameter and based on the users parameter the report is generated..(ITs working absoultely fine)
    but when the user runs the report again, its not showing the parameter page (i.e user cannot see poi.jsp)
    rather its showing the old generated report.
    When i tried using session.invalidate and session.removeAttribute it was showing me the poi.jsp page
    but the problem is when the user clicks on the print icon or any icon on the report its just
    showing the poi.jsp page...
    When the user closes the report or when the clicks on the button to generate the report it should
    show the parameter page (poi.jsp).how can i solve this problem???
    the code what iam using is as follows..( got it from the examples of CRE - database login )
    Object reportSource = session.getAttribute("reportSource");
    if (reportSource == null)
    String report = "CrystalReport2.rpt";
    ReportClientDocument reportClientDoc = new ReportClientDocument();
    reportClientDoc.open(report, 0);
    reportSource = reportClientDoc.getReportSource();
    session.setAttribute("reportSource", reportSource);
    ConnectionInfos connInfos = new ConnectionInfos();
    IConnectionInfo connInfo1 = new ConnectionInfo();
    connInfo1.setUserName("USER");
    connInfo1.setPassword("USER");
    connInfos.add(connInfo1);
    CrystalReportViewer viewer = new CrystalReportViewer();
    viewer.setReportSource(reportSource);
    viewer.setEnableLogonPrompt(false);
    viewer.setDatabaseLogonInfos(connInfos);
    if (session.getAttribute("refreshed") == null)
    viewer.refresh();
    session.setAttribute("refreshed", "true");
    viewer.setOwnPage(true);
    viewer.processHttpRequest(request, response, getServletConfig().getServletContext(), null);
    //session.removeAttribute("refreshed");
    //session.invalidate();
    thanks in advance
    regards
    jack

    As far as parameter refresh is concerned add in your code
    viewer.setHasRefreshButton(true)
    refresh button is appeared on crystal report toolbar and you can use this button instead of explorer refrsh button and every time you can add new parameters values.
    Also, if you want to update reportsource in session object. means if user wants to view more than one different reports and want to invalidate reportsource form session.
    add in jsp.
    session.removeAttribute("reportSource");
    Happy programming
    Uzma

  • How to clear the report from Cache.

    Hello all,,,
    In my project iam using crystsal report for eclipse to generate reports.
    Iam using a .jsp page to call my report.(which i got it from the examples of CRE).
    The name of my jsp page is poi.jsp
    The name of my Crystal report is Department.rpt
    My problem is this....
    when i run the report first time i can see my poi.jsp page and user can submit
    the parameter and based on the users parameter the report is generated..(ITs working absoultely fine)
    but when the user runs the report again, its not showing the parameter page (i.e user cannot see poi.jsp)
    rather its showing the old generated report.
    When i tried using session.invalidate and session.removeAttribute it was showing me the poi.jsp page
    but the problem is when the user clicks on the print icon or any icon on the report its just
    showing the poi.jsp page...
    When the user closes the report or when the clicks on the button to generate the report it should
    show the parameter page (poi.jsp).how can i solve this problem???
    the code what i am using is as follows
    try {
              String reportName = "C:/workspace/Reports/WebContent/Department.rpt";
              ReportClientDocument clientDoc = (ReportClientDocument) session.getAttribute(reportName);
              if (clientDoc == null) {
                   // Report can be opened from the relative location specified in the CRConfig.xml, or the report location
                   // tag can be removed to open the reports as Java resources or using an absolute path
                   // (absolute path not recommended for Web applications).
                   clientDoc = new ReportClientDocument();
                   clientDoc.setReportAppServer(ReportClientDocument.inprocConnectionString);
                   // Open report
                   clientDoc.open(reportName, OpenReportOptions._openAsReadOnly);
                   // ****** BEGIN SET RUNTIME DATABASE CREDENTIALS **************** 
                        String connectString = "jdbc:oracle:thin:@192.168.1.4:1521:orcl";
                        String driverName = "oracle.jdbc.driver.OracleDriver";
                        String JNDIName = "orcl";
                        String userName = "act_db";               // TODO: Fill in database user
                        String password = "act_db";          // TODO: Fill in password
                        // Switch all tables on the main report and sub reports
                        CRJavaHelper.changeDataSource(clientDoc, userName, password, connectString, driverName, JNDIName);
                        // logon to database
                        CRJavaHelper.logonDataSource(clientDoc, userName, password);
                   // ****** END SET RUNTIME DATABASE CREDENTIALS ****************           
                   // ****** BEGIN CONNECT PARAMETERS SNIPPET ****************          
                        // STRING VALUE PARAMETER. 
                        String stringValue = request.getParameter("DeptId");;     // TODO: Fill in value
                        CRJavaHelper.addDiscreteParameterValue(clientDoc, "", "DeptId", stringValue);
                   // ****** END CONNECT PARAMETERS SNIPPET ****************     
                   // Store the report document in session
                   session.setAttribute(reportName, clientDoc);
              // ****** BEGIN CONNECT CRYSTALREPORTPAGEVIEWER SNIPPET **************** 
                   // Create the CrystalReportViewer object
                   CrystalReportViewer crystalReportPageViewer = new CrystalReportViewer();
                   String reportSourceSessionKey = reportName+"ReportSource";
                   session.removeAttribute("reportSource");
                   Object reportSource = session.getAttribute(reportSourceSessionKey);
                   if (reportSource == null)
                        reportSource = clientDoc.getReportSource();
                        session.setAttribute(reportSourceSessionKey, reportSource);
                   //     set the reportsource property of the viewer
                   crystalReportPageViewer.setReportSource(reportSource);
                   crystalReportPageViewer.setDisplayGroupTree(false);
                 session.removeValue("reportSource");
                   crystalReportPageViewer.setHasRefreshButton(true);
                   // Apply the viewer preference attributes
                   // Process the report
                   crystalReportPageViewer.processHttpRequest(request, response, application, null);
              // ****** END CONNECT CRYSTALREPORTPAGEVIEWER SNIPPET ****************          
         } catch (ReportSDKExceptionBase e) {
             out.println(e);
    Thanks In advance
    Regards,
    Amol Patil

    CrystalReportViewer viewer = new CrystalReportViewer();
    viewer.setReportSource(reportSource);
         viewer.setReportSource(reportSource);
         viewer.setHasRefreshButton(true);
         viewer.setOwnPage(true);
         viewer.setOwnForm(true);
         viewer.setHasExportButton(true);
         viewer.setZoomFactor(100);
         viewer.setPrintMode(CrPrintMode.ACTIVEX);
        viewer.setParameterFields(fields);
    viewer.setEnableParameterPrompt(true); --this line will prompt

  • SSRS Application to Retrieve Reports from the Report Server

    I have an application that is done using SSRS on visual studio and it connects to the report server on SQL server 2008 environment.
    I've been changing the existing reports using visual studio 2008 and modifying the reports on the report server. How do I add a new report to the application ? I created a new report and deployed it on the report server but it didn't show up in the application.
    I can access the application source code on visual studio 2010 and TFS (Team Foundation). Thanks. 

    Hi, 
    Thanks for the reply. This is a view and [AmountDue] is supposed to be [CurrentDueAmount] + [PastDueAmount] - [PaidAmount]. The view is not calculating [PaidAmount] right . Below is the complete code of the view. Do you see anything wrong in the code ?
    Thanks. 
    SELECT     [isi].[InvoiceID], [ii].[DueDate], [SubInvoiceID] = [isi].[ID], [INV_FacilityID] = [if].[ID], [if].[FacilityID],
    [iff].[FacilityFeeID], [LoanID] = NULL, [isi].[PortfolioID], [isi].[Portfolio], 
                          [PaymentType] = [isis_fee].[SectionType], [Name]
    = [iff].[Name], [ReceivedAmount], [dates].[CurrentDueAmount], 
                          [PastDueAmount] = CASE WHEN ISNULL([ReceivedAmount],
    0) > 0 THEN [pastdue].[PastDueFeeAmount] + ISNULL([ReceivedAmount], 0) 
                          WHEN ISNULL([ReceivedAmount], 0) 
                          < 0 THEN /* We bring past due to zero and
    apply reset to current. */ CASE WHEN [pastdue].[PastDueFeeAmount] + ISNULL([ReceivedAmount], 0) 
                          < 0 THEN 0 ELSE [pastdue].[PastDueFeeAmount]
    + ISNULL([ReceivedAmount], 0) END WHEN ISNULL([ReceivedAmount], 0) = 0 AND 
                          [pastdue].[PastDueFeeAmount] < 0 THEN 0 ELSE
    [pastdue].[PastDueFeeAmount] END, [PaidAmount] = CASE WHEN ISNULL([ReceivedAmount], 0) 
                          < 0 THEN /* We bring past due to zero and
    apply rest to current. */ CASE WHEN [pastdue].[PastDueFeeAmount] + ISNULL([ReceivedAmount], 0) 
                          < 0 THEN - ([pastdue].[PastDueFeeAmount]
    + ISNULL([ReceivedAmount], 0)) ELSE 0 END WHEN ISNULL([ReceivedAmount], 0) = 0 AND 
                          [pastdue].[PastDueFeeAmount] < 0 THEN - [pastdue].[PastDueFeeAmount]
    ELSE 0 END, [AmountDue] = [unpaid].[UnpaidFeeAmount], [ID] = [iff].[FacilityFeeID]
    FROM         [dbo].[INV_SubInvoice] isi JOIN
                          [dbo].[INV_Invoice] ii ON [isi].[InvoiceID]
    = [ii].[ID] JOIN
                          [dbo].[INV_Facility] [if] ON [isi].[ID] = [if].[SubInvoiceID]
    JOIN
                          [dbo].[INV_FacilityFee] iff ON [if].[ID] = [iff].[INV_FacilityID]
    JOIN
                              (SELECT     [sis_fee].[ID],
    [sis_fee].[SectionTypeCode], [SectionType] = [st_fee].[Name], [sis_fee].[INV_FacilityFeeID]
                                FROM      
       [dbo].[INV_SubInvoiceSection] sis_fee JOIN
                   [dbo].[INV_SectionType] st_fee ON [sis_fee].[SectionTypeCode] = [st_fee].[Code]
                                WHERE      [INV_FacilityFeeID]
    IS NOT NULL AND [StatusCode] = 'BILL') isis_fee ON [iff].[ID] = [isis_fee].[INV_FacilityFeeID] JOIN
                              (SELECT     [iffa].[SectionID],
    [AccrualDeterminationDateMax] = MAX([iffa].[AccrualDeterminationDate]), 
                   [AccrualDeterminationDateMin] = MIN([iffa].[AccrualDeterminationDate]), [CurrentDueAmount] = SUM([iffa].[AccruedFeeAmount]), 
                   [ReceivedAmount] = SUM([iffa].[ReceivedFeeAmount])
                                FROM      
       [dbo].[INV_FacilityFeeAccrual] iffa
                                GROUP BY [iffa].[SectionID])
    dates ON [isis_fee].[ID] = [dates].[SectionID] LEFT JOIN
                              (SELECT     *
                                FROM      
       [dbo].[INV_FacilityFeeAccrual]) unpaid ON [dates].[SectionID] = [unpaid].[SectionID] AND 
                          [dates].[AccrualDeterminationDateMax] = [unpaid].[AccrualDeterminationDate]
    LEFT JOIN
                              (SELECT     [SectionID],
    [PastDueFeeAmount] = SUM([PastDueFeeAmount])
                                FROM      
       [dbo].[INV_FacilityFeeAccrual]
                                GROUP BY [SectionID]) pastdue
    ON [dates].[SectionID] = [pastdue].[SectionID]
    UNION
    SELECT     [isi].[InvoiceID], [ii].[DueDate], [SubInvoiceID] = [isi].[ID], [INV_FacilityID] = [if].[ID], [if].[FacilityID],
    [FacilityFeeID] = NULL, [il].[LoanID], [isi].[PortfolioID], [isi].[Portfolio], 
                          [PaymentType] = [isis_loan].[SectionType], [Name]
    = [il].[Name], [ReceivedAmount], [CurrentDueAmount], [PastDueAmount] = CASE WHEN ISNULL([ReceivedAmount], 
                          0) > 0 THEN [PastDueAmount] + ISNULL([ReceivedAmount],
    0) WHEN ISNULL([ReceivedAmount], 0) 
                          < 0 THEN /* We bring past due to zero and
    apply rest to current. */ CASE WHEN [PastDueAmount] + ISNULL([ReceivedAmount], 0) 
                          < 0 THEN 0 ELSE [PastDueAmount] + ISNULL([ReceivedAmount],
    0) END WHEN ISNULL([ReceivedAmount], 0) = 0 AND 
                          [PastDueAmount] < 0 THEN 0 ELSE [PastDueAmount]
    END, 
                          [PaidAmount] = CASE WHEN [isis_loan].[SectionTypeCode]
    = 'LOAN_PRIN' THEN 0 ELSE CASE WHEN ISNULL([ReceivedAmount], 0) 
                          < 0 THEN /* We bring past due to zero and
    apply rest to current. */ CASE WHEN [PastDueAmount] + ISNULL([ReceivedAmount], 0) 
                          < 0 THEN - ([PastDueAmount] + ISNULL([ReceivedAmount],
    0)) ELSE 0 END WHEN ISNULL([ReceivedAmount], 0) = 0 AND 
                          [PastDueAmount] < 0 THEN - [PastDueAmount]
    ELSE 0 END END, 
                          [AmountDue] = CASE WHEN [isis_loan].[SectionTypeCode]
    = 'LOAN_PRIN' THEN [CurrentDueAmount] ELSE [unpaid].[AmountDue] END, [ID] = [il].[LoanID]
    FROM         [dbo].[INV_SubInvoice] isi JOIN
                          [dbo].[INV_Invoice] ii ON [isi].[InvoiceID]
    = [ii].[ID] JOIN
                          [dbo].[INV_Facility] [if] ON [isi].[ID] = [if].[SubInvoiceID]
    JOIN
                          [dbo].[INV_Loan] il ON [if].[ID] = [il].[INV_FacilityID]
    JOIN
                              (SELECT     [sis_loan].[ID],
    [sis_loan].[SectionTypeCode], [SectionType] = [st_loan].[Name], [sis_loan].[INV_LoanID]
                                FROM      
       [dbo].[INV_SubInvoiceSection] sis_loan JOIN
                   [dbo].[INV_SectionType] st_loan ON [sis_loan].[SectionTypeCode] = [st_loan].[Code]
                                WHERE      [INV_LoanID]
    IS NOT NULL AND [StatusCode] = 'BILL') isis_loan ON [il].[ID] = [isis_loan].[INV_LoanID] JOIN
                              (SELECT     [iffa].[SectionID],
    [AccrualDeterminationDateMax] = MAX([iffa].[AccrualDeterminationDate]), 
                   [AccrualDeterminationDateMin] = MIN([iffa].[AccrualDeterminationDate]), [CurrentDueAmount] = SUM([iffa].[ExpectedPrincipalAmount]), 
                   [ReceivedAmount] = SUM([ReceivedPrincipalAmount])
                                FROM      
       [dbo].[INV_LoanPrincipalAmortization] iffa
                                GROUP BY [iffa].[SectionID]
                                UNION
                                SELECT     [iffa].[SectionID],
    [AccrualDeterminationDateMax] = MAX([iffa].[AccrualDeterminationDate]), 
                  [AccrualDeterminationDateMin] = MIN([iffa].[AccrualDeterminationDate]), [CurrentDueAmount] = SUM([iffa].[AccruedInterestAmount]), 
                  [ReceivedAmount] = SUM([ReceivedInterestAmount])
                                FROM      
      [dbo].[INV_LoanCashInterestAccrual] iffa
                                GROUP BY [iffa].[SectionID]
                                UNION
                                SELECT     [iffa].[SectionID],
    [AccrualDeterminationDateMax] = MAX([iffa].[AccrualDeterminationDate]), 
                  [AccrualDeterminationDateMin] = MIN([iffa].[AccrualDeterminationDate]), [CurrentDueAmount] = SUM([iffa].[AccruedInterestAmount]), 
                  [ReceivedAmount] = SUM([ReceivedInterestAmount])
                                FROM      
      [dbo].[INV_LoanPIKInterestAccrual] iffa
                                GROUP BY [iffa].[SectionID])
    dates ON [isis_loan].[ID] = [dates].[SectionID] LEFT JOIN
                              (SELECT     [AmountDue]
    = [UnpaidPrincipalAmount], [SectionID], [AccrualDeterminationDate]
                                FROM      
       [dbo].[INV_LoanPrincipalAmortization]
                                UNION
                                SELECT     [AmountDue]
    = [UnpaidInterestAmount], [SectionID], [AccrualDeterminationDate]
                                FROM      
      [dbo].[INV_LoanCashInterestAccrual]
                                UNION
                                SELECT     [AmountDue]
    = [UnpaidInterestAmount], [SectionID], [AccrualDeterminationDate]
                                FROM      
      [dbo].[INV_LoanPIKInterestAccrual]) unpaid ON [dates].[SectionID] = [unpaid].[SectionID] AND 
                          [dates].[AccrualDeterminationDateMax] = [unpaid].[AccrualDeterminationDate]
    LEFT JOIN
                              (SELECT     [PastDueAmount]
    = SUM([PastDuePrincipalAmount]), [SectionID]
                                FROM      
       [dbo].[INV_LoanPrincipalAmortization]
                                GROUP BY [SectionID]
                                UNION
                                SELECT     [PastDueAmount]
    = SUM([PastDueInterestAmount]), [SectionID]
                                FROM      
      [dbo].[INV_LoanCashInterestAccrual]
                                GROUP BY [SectionID]
                                UNION
                                SELECT     [PastDueAmount]
    = SUM([PastDueInterestAmount]), [SectionID]
                                FROM      
      [dbo].[INV_LoanPIKInterestAccrual]
                                GROUP BY [SectionID]) pastdue
    ON [dates].[SectionID] = [pastdue].[SectionID]
    UNION
    SELECT     [isi].[InvoiceID], [ii].[DueDate], [SubInvoiceID] = [isi].[ID], [INV_FacilityID] = [if].[ID], [if].[FacilityID],
    [FacilityFeeID] = NULL, [il].[LoanID], [isi].[PortfolioID], [isi].[Portfolio], 
                          [PaymentType] = 'PIK Interest Applied', [Name]
    = [il].[Name], [ReceivedAmount], [CurrentDueAmount] = - [dates].[CurrentDueAmount], 
                          [PastDueAmount] = - CASE WHEN ISNULL([ReceivedAmount],
    0) > 0 THEN [PastDueAmount] + ISNULL([ReceivedAmount], 0) WHEN ISNULL([ReceivedAmount], 0) 
                          < 0 THEN /* We bring past due to zero and
    apply rest to current. */ CASE WHEN [PastDueAmount] + ISNULL([ReceivedAmount], 0) 
                          < 0 THEN 0 ELSE [PastDueAmount] + ISNULL([ReceivedAmount],
    0) END WHEN ISNULL([ReceivedAmount], 0) = 0 AND 
                          [PastDueAmount] < 0 THEN 0 ELSE [PastDueAmount]
    END, [PaidAmount] = - CASE WHEN ISNULL([ReceivedAmount], 0) 
                          < 0 THEN /* We bring past due to zero and
    apply rest to current. */ CASE WHEN [PastDueAmount] + ISNULL([ReceivedAmount], 0) 
                          < 0 THEN - ([PastDueAmount] + ISNULL([ReceivedAmount],
    0)) ELSE 0 END WHEN ISNULL([ReceivedAmount], 0) = 0 AND 
                          [PastDueAmount] < 0 THEN - [PastDueAmount]
    ELSE 0 END, [AmountDue] = - [AmountDue], [ID] = [il].[LoanID]
    FROM         [dbo].[INV_SubInvoice] isi JOIN
                          [dbo].[INV_Invoice] ii ON [isi].[InvoiceID]
    = [ii].[ID] JOIN
                          [dbo].[INV_Facility] [if] ON [isi].[ID] = [if].[SubInvoiceID]
    JOIN
                          [dbo].[INV_Loan] il ON [if].[ID] = [il].[INV_FacilityID]
    JOIN
                              (SELECT     [sis_loan].[ID],
    [sis_loan].[SectionTypeCode], [SectionType] = [st_loan].[Name], [sis_loan].[INV_LoanID]
                                FROM      
       [dbo].[INV_SubInvoiceSection] sis_loan JOIN
                   [dbo].[INV_SectionType] st_loan ON [sis_loan].[SectionTypeCode] = [st_loan].[Code]
                                WHERE      [INV_LoanID]
    IS NOT NULL AND [StatusCode] = 'BILL' AND [sis_loan].[SectionTypeCode] = 'LOAN_INT_PIK') isis_loan ON 
                          [il].[ID] = [isis_loan].[INV_LoanID] JOIN
                              (SELECT     [iffa].[SectionID],
    [AccrualDeterminationDateMax] = MAX([iffa].[AccrualDeterminationDate]), 
                   [AccrualDeterminationDateMin] = MIN([iffa].[AccrualDeterminationDate]), [CurrentDueAmount] = SUM([iffa].[AccruedInterestAmount]), 
                   [ReceivedAmount] = SUM([ReceivedInterestAmount])
                                FROM      
       [dbo].[INV_LoanPIKInterestAccrual] iffa
                                GROUP BY [iffa].[SectionID])
    dates ON [isis_loan].[ID] = [dates].[SectionID] LEFT JOIN
                              (SELECT     [AmountDue]
    = [UnpaidInterestAmount], [SectionID], [AccrualDeterminationDate]
                                FROM      
       [dbo].[INV_LoanPIKInterestAccrual]) unpaid ON [dates].[SectionID] = [unpaid].[SectionID] AND 
                          [dates].[AccrualDeterminationDateMax] = [unpaid].[AccrualDeterminationDate]
    LEFT JOIN
                              (SELECT     [PastDueAmount]
    = SUM([PastDueInterestAmount]), [SectionID]
                                FROM      
       [dbo].[INV_LoanPIKInterestAccrual]
                                GROUP BY [SectionID]) pastdue
    ON [dates].[SectionID] = [pastdue].[SectionID]

  • Error retrieving Report from omniture servers

    Anyone having analytic problems at the mo?

    I'm still getting it now so I'm guessing it wasn't set up properly when the issue was built.
    Thanks Lukas

  • OLAP-Cache filling and report retrieval from cache

    Dear All,
    I am expecting good information from you guys in regards to process of OLAP-Cache filling and retrieval process.
    Let's say, we have few selectios as below to fill cache.
    selection 1:
    Calmonth : 201006
    Plant : A1 to A3.
    OLAP cache is filled with the above selection1.
    Selection 2:
    Calmonth : 201006
    Plant : A4 to A5
    OLAP cache is filled with the above selection2.
    When I am exeuting a query with the selections as below, how the data will be retrived? Is it from Cache memory or DB?
    Selection: Calmonth 201006 and Plant A3 to A4.
    Would be really Appreciate If I get some valuable information.
    Regards,
    KS

    Thanks for valuable information.
    I have used the mode as "Persistent Cache per Application Server" and " Transparent Table (BLOB)"
    What I am realizing here is, If the query selection is different from the cache selection, it is reading it from DB though the requested data is availabe in cache as per the below eg.
    Cache Memory:
    Selection1: Calmonth : 201006 and Plant : A1 to A2
    Selection2: Calmonth : 201006 and Plant : A3 to A4.
    Query Selection:
    Calmonth : 201006 and Plant : A2 to A3.
    Regards,
    Kanagaraj.S

  • Query Report:To Retrieve Data from A/R Invoice and A/P Invoice

    Hii Experts,
          I am a new Sap B1 Trainee.I am facing a problem when retrieving data from A/R Invoice and A/P Invoice in order to track
    Expenditure and Revenue according to a Bussiness partner,
    I am using union to retrieve the information,but it is saying a error that  Error Converting Varchar to Numeric and also
    i would like to know how can i show the total final payment by reflecting Downpayments in A/R Invoice and A/P Invoice
    With Regards
    Cherry.

    Hii.
    My Sap B1 version is 8.8.1 and patch level is 20. Actully i need a scenario where i can able to show both Expenditure and Revenue of a particular bussiness partner and profit/loss in a single query report.
    I need some tips regarding this,When i am doing union i am getting conversion error converting varchar to numeric when i take
    Sum(Line Total) from OINV and Sum(line total) OPCH group by docdate and docentry and BP .
    and another scenario is how to deduct A/P downpayment or A/R downpayment from A/P invoices and A/R invoice to get the final Revenue and Expenditure ..
    Thanks & Regards
    Cherry

  • Webi report: Issue Cannot retrieve dimensions from Cube

    Hello Experts,  We're facing an issue with a partical set of Webi reports in Quality environment. The reports are BW reports based on OLAP BICS connectivity on top of Bex queries.y  Below is the scenario and the issue:  1. The backed Bex queries have been trasported to Quality BW system and they're running fine when run from RSRT or Bex analyzer. 2.The Webi reports along with the BICS connections have been migrated to the Quality box and the BICS connections have been editied so that they point to the Quality BOX bex queries and they're testing and responding to the connection successfully. 3. The Webi reports pointed to the Dev Box in the Dev BOBJ system are working fine, but when the same reports for which the connections were repointed in Quality as above, are giving the error "Cannot Retrieve Dimensions from Cube".  Steps taken: a. Deleted the reports and the BICS connection from Quality environment and remigrated the reports,connecitons and changed the connecitons but still the issue persists. b.Tried finding the root cause and got the following issue in the Bex query in Quality: There are filters put in the Bex query . All other filters are working fine except 0CALMONTH. We tried putting all sorts of variables on 0CALMONTH, but the moment a variable is put on 0CALMONTH, this issue occurs. But when we tried removing the variable from 0CALMONTH in filters and restricted it to a single value, the Report works fine.  However the same is not an issue in the Dev Box and all queries with similar variables are working fine.  So we're thinking this might be an issue on the BW backend and the cube might have to be transported again to the Quality Box.  ANy quick suggestions or inputs on this would be greatly appreciated.  Thanks and regards, Abhishek

    Hi Abhishek,
    I am facing same issue.Have you resolve this issue?
    Regards,
    Rajesh

  • Crystal Reports - Failed to retrieve data from the database

    Hi There,
    I'm hoping that somebody can help me.
    I've developed a crystal report from a stored procedure which I wrote. I can execute the stored procedure within SQL Server and within the Crystal Reports designer without any errors. Furthermore, I have imported the report into sap and can run it within SAP from the server without any errors. SAP version 8.81 PL5
    The issue is that when it's run from a client machine, I get the following error: "Failed to retrieve data from the database. Details: Database Vendor Code: 156. Error in the File RCR10010 {tempfile location}
    Here's a list of things which I have tried, all to no avail:
    - Checked user permissions to ensure that they have proper authorizations
    - Re-set the datasource connection and re-imported the report to SAP.
    - Exported the report and reviewed the datasource connection and re-imported to SAP.
    - Tried to run the report on multiple machines to ensure that it's not machine specific
    - Tried to run the report using different users to ensure it's not user specific.
    - Tested other reports built from stored procedures on client machines to ensure that they work.
    Any assistance in this would be GREATLY appreciated.
    Thank you

    After further testing, we found that the report could be run within SAP on any work station which had the CR designer installed on it.
    As it turns out, the procedure which I wrote has temp tables in it.  The runtimes built into the SAP client install do not support creating temp tables when executing the report from within SAP.  Which is why the report could not retreive data.
    To work around this, I installed external runtimes which were the same version of the Crystal Report and now the report can be run within SAP from any workstation which has the external runtimes (and not just the runtimes within the SAP client).
    I hope this makes sense.

  • Failed to retrieve data from the database crystal reports 2008 in SAP  B1

    Hello friends,
                 I am using Crystal report 2008 with SAP B1 PL 8.8. When I run any report,  it runs correctly from Crystal Report. But whenever I try to open the same report through SAP ( Tools -> Preview External Crystal Report ), it prompts the parameters for that report and then open up the crystal report window and throws an Error message ("failed to retrieve data from the database. Details [Database Vendor Code: 156]").
               Please any one suggest me the corrective solution.
    Thanks in Advance,
    Keyur Raval.

    I had the same problem in SAP B1 2007. Report worked fine except when it was open from B1. Generally there may be different problems. In my case the same problem was caused by using some procedure which was in a specific schema. Changing the schema into "dbo" solved the problem.
    Radoslaw Blaniarz

  • Creating Rpt Conmgr Cache File In Temp folder while opening report from app

    hi frends,
    I m facing one problem with my Web based erp application which is developed in .net ,
    in my application when i open the  report from my applicaiton , in my temp folder there one file gets created name is "rpt conmgr cache"
    bcoz of this for few records also my report takes too much time and opens very slow and it takes long time, and it happens in some of the reports only , other reports are working cool and its not creating any file in temp folder,,,
    so can u guide me whats this file and what can be the solution for it,
    Thanks
    Mithun

    I have never heard of "rpt conmgr cache" being created in any temp directory. Is that the actual name of the file you are seeing?
    As you have not applied any updates, I'd recommend applying SP 4 to your development system. SP 4 is here:
    https://smpdl.sap-ag.de/~sapidp/012002523100006255422008E/crxir2_sp4_inc.exe
    Next, I'd recommend getting the SP 4 runtime on the client. You have two options; MSI file of create your own deployment sing the msm files. The MSI file is here:
    https://smpdl.sap-ag.de/~sapidp/012002523100009657852008E/crxir2sp4_net_si.zip
    MSM is here:
    http://resources.businessobjects.com/support/communityCS/FilesAndUpdates/crxir2sp4_net_merge_modules.zip
    Also, I don't think I still have a good handle on this:
    "my report takes too much time and opens very slow and it takes long time"
    What is long time? Two seconds, two minutes, etc.?
    Ludek

  • Crstal Reports: "Failed to retrieve data from the database"

    Running a report in crystal report from SAP 8.81 using the following parameters: CardCode, GroupCode, Date gives the following error: "Failed to retrieve data from the database" "Conversion failed when to converting the nvarchar value to data type int 12/31/2005 [Database vendor code: 245] ".
    The store procedure in SQL Server executes smoothly and  If you run the report with the date = 12/31/2005 in the parameter also returns expected results.
    Thanks.

    Hello,
    Is this in Business One? If so CR is an OEM build and that forum/product supports that version.
    Please post your question to: http://forums.sdn.sap.com/index.jspa#44
    It could simply be you need to use a formula to convert the field. Click on the Formula Editor and the hit the F1 key and search on "date". Lots of info on how to convert todate and from date tostring...
    Thank you
    Don

Maybe you are looking for

  • Regularly auto creation of sales order

    Hi All, Is it possible to define or set auto creation of sales order ? e.g. there 2000 customers that every biweekly Monday will have sales orders created automatically by system, so the user just only see and copy to delivery or A/R invoice. TIA Rgd

  • How do I bind 10.4 clients to a 10.5 server?

    I've been given the task of cleaning up a Mac network that has 15 iMacs....some running 10.4 and some 10.5. 2 issues 1 - as a test I created an account called MacA on the server, and there are only 6 other accounts listed in the server....BUT, some o

  • If I upgrade to Mountain Lion on my iMac will I be able to open my Photoshop CS4 in order to resize

    If I upgrade to Mountain Lion on my iMac will I be able to opwn my Photoshop CS4 in order to resize and adjust RGB of photos of my artwork? I use the Photoshop for very little else at this point in time. Thank you

  • DNS resolving when it shouldn't be able to

    I have an AEBS set up to share a single IP via a PPPoE DSL connection. I have a Mac OS X Server whose network ethernet connection is manually configured with a static (internal) IP, router IP is set to the AEBS and DNS is set to 127.0.0.1 On that sam

  • Re engineering of existed process / Best Practice (customization)

    Hi all of you, We are implementing SAP ECC 6.0 for one of our clients. Client is asking us to compare their existed business process with Best Practice / standard process and based on the result, asking to prepare a GAP analysis between the existed a