Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- SIx Driver RDD v3.00 - Reference Guide - <b>m6_dbeval():</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
  m6_dbEval():

  Purpose:  Performs an optimized scan of a database evaluating a code block
            based on records that meet the FOR criteria.

   Syntax:  m6_dbEval( <bEvalBlk>, <cForExpr>, <bForBlk> )

    Where:  <bEvalBlk> = Code block to be evaluated
            <cForExpr> = FOR criteria as a string
            <bForBlk>  = FOR criteria as a code block

     Note:  In the event the expression is deemed non-optimizable, <bEvalBlk>
            and <bForBlk> will be passed on to Clipper's dbEval() for
            evaluation.

  Returns:  NIL


  Example:

        #include "SIXCDX.CH"
        #include "MACHSIX.CH"

        LOCAL bEval := {|| NIL }, cFor, bFor

        USE Salesmen INDEX Sales

        //..................................................setup params
        bEval := {|| bonus += 1000.00 }
        cFor  := "sales > 25000"
        bFor  := {|| sales > 25000 }

        //..............................................give 'em a bonus
        m6_dbEval( bEval, cFor, bFor )



See Also: m6_RecCount()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson