Show Previous Balance value in Report.

Hi,
I'm using Crystal Reports with Visual Studio 2010. I'm generating a report which shows columns Debit and Credit and SUM values on the buttom of each column. The report is filtered using a date range, which I specify in my connection via C# code (below).
            string sqlString = "";
            sqlString = "SELECT * FROM Ledger WHERE ([Payment Date] >= #" + FromDate + "#) AND ([Payment Date] <= #" + ToDate + "#)";
Now I need a "Previous Balance" value, which would be the SUM of Credit and Debit columns, which are prior to "Payment Date".  How do I accomplish this?  I've attached a sample of the report I'm looking for. Please be specific with your reply, because I'm new to Crystal Reports.
Thank you so much for your help.
Aron

Hi Aron,
Crystal is database agnostic, meaning it will run a report against any database.  If you create a report using AS/400 it's possible to use that same report against an Oracle or SQL Server database as long as the recordset Crystal is expecting is the same.
So having a report run from a Stored Procedure will work on different databases as long as the metadata for the Stored Procedures between the databases match.
For the subreport, when  you drop the subreport into the Group Footer.  Right-click on the subreport and you have the option to Link Subreport.  You can select the OwnerID from the main report and link it to the OwnerID in the subreport.
Your c# suggestion may be going the long way around the barn.  If you link the subreport in your Group Footer 1, you should be able to get the Previous Balance for that OwnerID.  When you link the subreport, it creates a Record Selection Formula in the subreport that should return only the records for that OwnerID.
Once you have the subreport linked, edit the subreport and go to Report | Selection Formula | Edit Record Selection Formula.  You'll see what the linking created.  You can now edit that formula to include your date range that is outside the current period.
Hope this helps,
Brian

Similar Messages

  • Need to show Previous months data in report

    Hi All,
    I have a crystal report 2011 which shows monthly Cash data. It has 3 other columns like Previous 3 months cash data, previous 6 months cash data, Previous 12 months cash data in report.
    My report also has two parameters- start date and end date. If I give Start date as 1/1/2012 and end date as 12/31/2013 (two years date range) then correct data comes in all columns and for 2013 year, correct data is coming for Previous 12 months column. But if I give only one month date range like start date as 1/1/2013 and end date as 01/31/2013, then it is not showing correct data for these 3 columns - Previous 3 months cash data, previous 6 months cash data, Previous 12 months cash data. Ideally as per requirement, it should calculate previous months data regardless of parameter values and put data in respective columns.
    Any help/suggestion? Any trick which can help me to show correct data in all columns no matter what date range or months I am taking in parameters.
    Is it mandatory to have previous 12 Months data in report to calculate column-Previous 12 months Cash data?
    Thanks,
    Remi

    Hi Remi,
    You can try like this:
    I have given a some suggestions i.e You just take one parameter only because u can imagine 3 columns previous data display correctly i.e From Date
    Month parameter is also a alternate option.
    For Ex: Column1: From Date - 90 Days/3 Months  - we get the three months previous data correctly etc.
    Finally, create a stored procedure that returns the required columns and does all the calculations on the database side.
    Follow abhilash suggestion as well.
    Useful threads: Crystal Report Parameter Issue
    Pull Last 6 months of data
    Month to date data for Previous month
    How to find current month, previous month Net Sales by means of formula?
    Thanks,
    DJ

  • Report Parameter form not showing list of values in Report svr

    I was using reports 6i where I used to have list box in report parameter form. I now converted recompiled my reports in 10g and when I run I am not geting the list of values. I get the values as a list below the field
    ex.
    ITEM :___________
    box,book,pencil,rubber,
    dvd,floppy...
    previously it was coming as a list in the item field
    thanks
    MG

    Hello,
    http://www.oracle.com/webapps/online-help/reports/10.1.2/topics/htmlhelp_rwbuild_hs/rwwhthow/howto/params/pmp_creating_list_of_values.htm?tp=true
    If you run the report from a Web browser and the list of values is unrestricted, the HTML Parameter Form will display a text field instead of a combo box, and a list of static values that you can copy and paste into the text field.
    Regards

  • Display previous month value in report

    Hi,
    I have a requirement to display the previous month amounts on monthly basis. here is the example.
    In the Cube I have data like this:
    <b>Customer   Month         Amount</b>
    C1        Jan 2004        $500
    C1        Feb 2004        $600
    C1        March 2004      $1000
    I want to display in Report with another key figure to show the difference between current month and previous month. Report should look like:
    <b>Customer   Month  Amount  <i>Prev_Month_Amount     <u>Diff</u>.</i></b>
    C1      Jan 2004   $500         0               $500
    C1      Feb 2004   $600       $500              $100
    C1      Mar 2004   $1000      $600              $400
    I have tried using restricted key figures.but it is showing the same amount in prev. moth amount colunm till feb 2004. anyone had similar req. please advise me.
    Thanks in advance,
    Ram

    Hi,
    I can only think about a 2 structure approach with cell calculations.
    This will result in a static report with 12 rows for each customer. Then you would need to use the new feature of zero supression, to hide those month where no data exists.
    Heike

  • Showing master data value in report for which no record in Infoprovider

    Hi,
    We have the following reporting requirement. The master data values , e.g. 0Customer should appear in the report for which no sales has taken place, i.e no record in Infocube.
    We have defined a multicube using Infoprovider & 0Customer Infoobject, but the report seems to show only values from InfoCube, not the values which are not there in infoprovider but are present in infoobject.
    Please suggest.
    Thanks & Regards
    Madhu
    00919830957798

    Madhu,
    There is a how to paper on how to do this. It available in the BW InfoIndex under Multiproviders and is called Slow Moving Inventory Scenario.
    https://service.sap.com/~sapidb/011000358700008387152002
    This document details out the process of reporting on master data values for which no transactions ahve been recorded. This is achieved by creating a MultiProvider on a Cube and InfoObject and then using teh record count property.
    Cheers
    Aneesh

  • Show Repeated key values in Reports and Export Into Excel

    Hi Experts,
    Currently I am working on the BW3.5 version. Our client requirement to display the repeated key value in web and export same into excel. I have followed the steps in web template which mentioned below to achieve the requirement.
    1) In my web template, add the following line to the Template Properties object tag (the tag at the very top of the web template in HTML mode):<param name="SUPPRESS_REPETITION_TEXTS" value=""/>
    After the change web template change, Myself execute the report in web, Its fine web. But I export into excel, again the key values are suppressed. So I have followed the steps in query. Then its fine. I mean, I can export into excel with repeated key values.
    2) In my query, in Properties and on the Display tab, unchecked "Hide Repeated Key Values".
    But do we have any other option without changing query properties to achieve the requirement.. I am fine with the web template change("SUPPRESS_REPETITION_TEXTS"). But I do not want to change the query properties.
    Please help me to fix the issue. Thanks in advance.
    Thanks,
    RR

    Hi Experts,
    I have come across one of the suggestion in the below location. Could you plz help me to implement it.
    http://www.sapfans.com/forums/viewtopic.php?f=16&t=118185
    Suggestion:
    You can do exactly what you want, but it will take either a button changing the properties of the web item or a javascript function added to the context menu getting the properties of the table item and changing it to "X" or "". These are just two examples, there are other ways to do this. This is the actual code that sets the suppression for the repeated texts. Hope this helps.
    SAP_BW_URL item=âu20ACu2122TABLE_1âu20ACu2122 SUPPRESS_REPETITION_TEXTS=âu20ACu2122Xâu20ACu2122
    Thanks,
    RR

  • What is table name and field name for balance value in sales order in sap

    hi i want to make FS for sales order status report .and i want balance value in report please tell me about table field name of balance value.

    You can get the Sales Order status in Table VBUK & VBUP at Item Level.
    To achieve the Open Value , first consider the Open Quantity.Refer VBAP - KWMENG (Order Quantity) , then from LIPS - LFIMG (Delivery Quantity) , you will get the Open Quantity & then accordingly you will get the open Value.
    Best Regards,
    Ankur

  • Reporting Issue   "Opening Balance values are going to Not Assigned Values"

    Hi Friends,
    Closing Balance values are perfectly showing but opening balance values are going to Not Assingned Values? I am not able to find it out.
    our query is built on PCA Daily Multiprovider.
    Pls Help.
    Thanks
    Asim

    Hi Ravish,
    Here are the details
    Stock values and quantities in the PCA cube of BW never show correctly at an article level due to an opening balance issue.  This reduces our ability to report on stocks at moving average price, i.e. anything that actually matches the financial values in the system. The issue arises because stock at the beginning of the year (quantity and value) for any site is only shown against an article of "Not assigned."  Stock movements during the year are shown against the appropriate article.(If you have a new site, the will have stock assigned against an article up until 31 December and then the 31 December values are shown against "not assigned" for the next year).
    Thanks
    Asim

  • Asset report S_ALR_87011963 is not showing the asset values for perion 08

    Hi,
         The internal order number is 400011.The amount 38,300 were booked on this order. I have settled  38,050 into 7 assets hence the balance is 250 in this internal order (Work in progress 100050).
    When i check the Asset expolorer, there it is showing me this remaining value. But when i run any asset report, say Transaction code - S_ALR_87011963(Asset balances) with report date as 30/05/2008 for period 8, the asset 100050 is showing as NIL Value. But if i run it with date as 30/09/2008 for period 12, then it is showing the balance amount.Our fiscal year is frorm Oct- Sep.
    I don't understand why this difference is coming. It should show the balance 250 at the end of period 8.
    The last input on this internal order was in March 08 when I transfered most of the costs to the assets.So no reason to have a difference depending on the date of the report.
    The internal order 400011 is having status as Released at present.
    Can anyboday help me on this. Points will awarded.
    Earliest reply will be highly appreciated.
    Regards,
    Shree.j

    Hi Rau,
    Could you please me How to Upload the GL or Open Item Balances on Month to Month Basis? for this we still use FB01 for Initial Upload?
    My Client is giving the balance for last year Monthly with daily Transactions with past Posting dates obviously,do I need to Upload with same Posting dates or with Current Posting date?
    For reporting Purpose My Client would like to see Monthly Balances of Open items for Initial Upload,"is this same as Month to Month Upload you advised above"?
    What is the Difference b/w Month to Month ORr Just one Amount as total balance uploaded to SAP? which is Best Practice before Initial Upload?
    Thank you ,
    Paarthaa...

  • Items with  zero stock quantity show negative stock value in Stock reports

    When running Stock reports for controlling the stock value towards the GL accounts, some items appear with zero stock quantity, but the report still shows a stock value  (negative value in my case)
    How can this happen, and how can I correct this situation ?
    System parameters are :   negative stock is not allowed, Items with zero cost price not allowed. On item level average cost price method is used.
    P.K.Johnsen

    Hi Johnsen,
    I believe you have checked the" Manage Inventory by warehouse". I have noticed this issue in SAP B1 2005B but this is rectified in 2007B. The system behaves in this way as the system maintains item cost for the item for all warehouses and even if the stock is not present in the warehouse, the system would still show you a value for the same. Hope this helps. please search the forum. You'll find related threads.
    Thanks,
    Joseph

  • "Invoice History Report "show wrong balance for supplier invoice with USD

    Invoice History Report show wrong balance for supplier invoice with USD Currency
    After I run this report i see in the last of this report there is difference between the supplier total
    USD (Currency ) and the open Balance USD , it is decreased the open balance
    for supplier with 2300 USD with out any reasons
    bellow is some data copy of the report
    ======================================================
    Supplier Site Total: SAR 34,700.00
    Supplier Site Total: USD 39,000.00
    Supplier Total: SAR 34,700.00
    Supplier Total: USD 39,000.00
    Open Balance: SAR 34,700.00
    Open Balance: USD 36,700.00
    *** End of Report ***
    ==============================================
    please advise me from where can this differenc ( 39000 - 36,700=2300 )COMMING
    or it is bug in this report , becuase i compare this report with other report in account payable like
    -supplier open balance letter
    -invoice register report
    -invoice aging report
    all this report give me the amount for supplier USD =39000
    BUT AGIN FROM WHERE THE SYSTEM DECREASED THE AMOUNT TO 36,700
    thanks

    Can you try running Create Accounting For payments just before you run the Invoice History Report and re-check .
    Thanks

  • CJI5 commitment line item report not showing po gross value

    Dear All,
    system is showing only net value in CJI5 report, actaully gross value of po must be reflected in CJI5 report and this happening in all po's like material, service's etc. example is as follows.
    Example:
    po net value: 1000
    st 10%: 100
    po gross value : 1100 (inclusive of all taxes, ed, disc. etc)
    what could be the reason for not showing po gross value in commitment line item report.
    Thanks & Regards,
    Sandeep

    Hi,
    As far as i know the commitment report will never show you the value that is inclusive of taxes. It will only show the net value of the PO.
    I just tried a scenario in my system by creating a PO for a net value of 3000 GBP and based on the tax code i entered system calculated a tax of 525 GBP. However when i check CJI5 report it shows only 3000 GBP as commitment and not 3525 GBP. This is how the standard system behaves, i believe. You can cross check this in the table COOI. The COOI table also shows the net value of the PO and does not include the tax amount in commitment.
    Regards,
    Gokul

  • How to show register attribute value in my register users report in FIM 2010 R2

    Hi,
    How to show register attribute value in my register users report in FIM 2010 R2?
    Please suggest on this.
    Regards
    Anil Kumar

    hello,
    the only way I know is manage the attribute descriptiona s a property and then enable the pivot table option "Show properties in tooltip".
    But I'm interested in what you mean with  "using
    "OLAP pivot table extension" is an option". How this works?
    Thanks
    bye
    Norman

  • COPA report showing as positive values which should be show as Nagitive val

    Dear Experts
    I have one issue with COPA and Profit center reports reconciliation where the both have same structure
    user  compareing the (Period :dec 2011)  report PCA and COPA there identified some values are difference  so we started investgation
    one of the cost element showing in nagitive value in accoungint document and same  it is showing postive value in COPA report
    that values for debit and credit line items are adding (,) insted of Cancellation  (+,-) , so that COPA report is incresed the value for one value field when compare with PCA report line items
    could you please let any guide me where is the problem is occuring
    thanks
    Rana

    Hi,
       The COPA sign logic depends on the cost element type used (costs or revenues) and also the customizing of the '+/-  transfer sign' in tcode KE4I.
    The following table shows an overview of how condition values are
    updated in CO-PA for billing documents from SD:
    Billing document (normal) "With +/- sign"    "Without +/- sign"
    Debit posting                          negative            positive
      (such as sales deductions)
    Credit posting                         positive            positive
      (such as sales revenues)
    Credit memo/return         "With +/- sign"    "Without +/- sign"
    Debit posting                          negative            negative
      (such as sales revenues)
    Credit posting                         positive            negative
      (such as sales deductions)
    The "+/- sign" refers to the "Transfer +/- sign" flag in tcode KE4I where you assign SD conditions to COPA value fields.
    If the system is behaving as shown above and you want a different behavior then you could change the sign in user exit COPA0002.
    regards
    Waman

  • Spark datagrid that shows the new  value and that it previously was

    Im trying to create a item renderer for a spark datagrid that shows the new  value and that it previously was and I am comparing in the set data, the problem I am having is that in teh set data I am frequently getting data from other rows (I know this because of virtual renderders), it there a way round this?
    <?xml version="1.0" encoding="utf-8"?>
    <s:GridItemRenderer xmlns:fx="http://ns.adobe.com/mxml/2009"
                        xmlns:s="library://ns.adobe.com/flex/spark"
                        xmlns:mx="library://ns.adobe.com/flex/mx"
                        currentState="unmodified">
        <fx:Script>
            <![CDATA[
                override public function set data(value:Object):void
                    if(data){
                        if(super.data.margin != value.margin  && super.data.margin){
                            oldValue.text = '(' + super.data.margin + ')';
                        }else{
                            oldValue.text == '';
                    super.data = value;
                    stroke.visible = false;
                    fillRect.visible = false;
                    if(data){
                        if(this.data.isModifiedClientSide){
                            currentState = "modified";
                            fill.color = 0xddddff;
                            stroke.visible = true;
                            fillRect.visible = true;
                        else{
                            fill.color = 0xffffff;
                            stroke.visible = false;
                            currentState = "unmodified";
                            fillRect.visible = true;
            ]]>
        </fx:Script>
        <s:states>
            <s:State name="modified"/>
            <s:State name="unmodified"/>
        </s:states>
        <s:Rect top="0" left="0" right="0" bottom="0" id="fillRect" >
            <s:fill><s:SolidColor id="fill"  color="0xFFffff"  /></s:fill>
        </s:Rect>
        <s:Rect left="1" top="1" right="0" bottom="0" id="stroke">
            <s:stroke >
                <s:SolidColorStroke color="0x000099" weight="1"  >
                </s:SolidColorStroke>
            </s:stroke>
        </s:Rect>
        <s:HGroup horizontalAlign="center" verticalAlign="middle" top="0" left="0" right="0" bottom="0" paddingRight="5">
            <s:Label text="{data.margin}" width="50%" textAlign="right">
            </s:Label>
            <s:Label  id="oldValue" color="0xff0000" width="50%"  textAlign="right">
            </s:Label>
        </s:HGroup>
    </s:GridItemRenderer>

    If I recall correctly, you are talking about the default start page. To check if this is correct, type '''about:home''' in the awesome bar. If this is the same as your homepage, it will still be there when you update.

Maybe you are looking for

  • Importing data to excel

    My problem is that excel can't open the entire txt file that I am generating. How can i get all of data to go into excel since now it just fills up the entire A column with data and that is only 65,536 cells. Is there a way to get the data to fill up

  • Error with ABAP proxy

    Hi all, I have an ABAP proxy - XI - Webservice scenario, in the XI side we are getting error saying input data not coming in. How to check weather proxy is triggering the actual payload or data? There has been a change in the WSDL from the Webservice

  • Can OUT parameters be used in 10g's PL/SQL

    Hi: Are OUT parameters supported in the PL/SQL version that comes with 10g (Forms and Database)? Thanks for your help, Thomas

  • Having trouble getting multiple tables to post to the same report

    I have a canned report that is being generated from one source and I am trying to add a field from a different SQL source table. The report is being run in STAGES but every time I try to run the report I am getting an error report. There are several

  • Unable to succcessfully connect monitor to laptop

    Hi all. I received the lovely 23" W2371d monitor for Christmas. I have been unsuccessful in connecting it to my Sony laptop F series. I have installed the cd information and connected the cable to one another. Both the VGA and DVI shows no signal. An