CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Aug 2011
    Posts
    4

    [RESOLVED] Referencing another row in a table?

    I'm trying to create a report of our customer's chemical usage. We have an Invoice table with a row that has the part name and then the quantity. One of our quantities we have to subtract from another. So I need the subtotal to be the actual total - one of the other totals. I couldn't figure this out on my own.

    Sorry if I sound frustrated!

  2. #2
    Join Date
    Jul 2005
    Posts
    1,083

    Re: Referencing another row in a table?

    Welcome to CodeGuru Forums !

    If you can identify the rows then you can use a formula field
    JG


    ... If your problem is fixed don't forget to mark your threads as resolved using the Thread Tools menu ...

  3. #3
    Join Date
    Aug 2011
    Posts
    4

    Re: Referencing another row in a table?

    The issue I'm having is that I'm not sure which row it'll process first.

  4. #4
    Join Date
    Aug 2011
    Posts
    4

    Re: Referencing another row in a table?

    Is there a way to control which order they get processed in? Does sorting affect that?

  5. #5
    Join Date
    Aug 2011
    Posts
    4

    Re: Referencing another row in a table?

    Turns out it did. I tried it earlier, but I must've just had something wrong in one of my formulas.

  6. #6
    Join Date
    Jul 2005
    Posts
    1,083

    Re: [RESOLVED] Referencing another row in a table?

    Also it would be helpful to know about the reporting specific functions:
    BeforeReadingRecords
    WhileReadingRecords
    WhilePrintingRecords
    EvaluateAfter.
    You can use these functions to guide Crystal Reports as to when your formula should be evaluated.

    Should the formula be evaluated before retrieving the records from the database, while reading the records from the database but before the records have been grouped, sorted and summarized, or while printing the report, when the records are grouped, sorted and summarized?
    In general, Crystal Reports sets an appropriate evaluation time for your formula, based on how much information the formula needs
    JG


    ... If your problem is fixed don't forget to mark your threads as resolved using the Thread Tools menu ...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured