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_filtinfo():</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
  m6_FiltInfo():

  Purpose:  Get information about a specified filter.  Filter may be
            a system or RYO filter, all you need is a valid handle to
            the filter.

   Syntax:  m6_FiltInfo( <nHandle> )

    Where:  <nHandle>      --  Is any valid handle to a filter.

  Returns:  A single dimensional array containing information about the
            specified filter.

     Note:  Use the following constants defined in MachSIx.ch to reference
            the elements of the info array.

            #define INFO_EXPR         1  // Complete filter expression
            #define INFO_NONEXPR      2  // Non-indexed expression
            #define INFO_OPTLVL       3  // Optimization level
            #define INFO_COUNT        4  // Number of records in filter
            #define INFO_SIZE         5  // Maximum valid record no.
            #define INFO_OWNER        6  // Filter Owner, 1=System, 2=User
            #define INFO_POS          7  // Current position in filter

            *Always free RYO filters that are no longer being used.*
  Example:

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

         USE Customer via "SIXCDX"

         SET INDEX TO State

         //...............create a RYO filter based on a query condition
         nHandle := m6_NewFilter( 'State = "CA" .and. Age = 25' )

         //.............................get information about the filter
         aInfo := m6_FiltInfo( nHandle )

         //.......................................display filter details
         ? "Filter information"
         ? "------------------"
         ? aInfo[ INFO_EXPR    ]      //  STATE="CA".AND.AGE=25
         ? aInfo[ INFO_NONEXPR ]      //  AGE=25
         ? aInfo[ INFO_OPTLVL  ]      //  1
         ? aInfo[ INFO_COUNT   ]      //  100
         ? aInfo[ INFO_SIZE    ]      //  10000
         ? aInfo[ INFO_OWNER   ]      //  2
         ? aInfo[ INFO_POS     ]      //  1

         //...........................free memory allocated to RYO filter
         m6_FreeFilter( nHandle )

         //.........................................set a workarea filter
         SET FILTER TO "State='CA'"

         //.........................................initialize the filter
         GO TOP

         //....get a handle to the filter ( note: it's still system owned )
         nHandle := m6_GetAreaFilter()

         //.............................get information about the filter
         aInfo := m6_FiltInfo( nHandle )

         //.......................................display filter details
         ? "Filter information"
         ? "------------------"
         ? aInfo[ INFO_EXPR    ]      //  STATE='CA'
         ? aInfo[ INFO_NONEXPR ]      //  ""
         ? aInfo[ INFO_OPTLVL  ]      //  2
         ? aInfo[ INFO_COUNT   ]      //  100
         ? aInfo[ INFO_SIZE    ]      //  10000
         ? aInfo[ INFO_OWNER   ]      //  1
         ? aInfo[ INFO_POS     ]      //  1



See Also: m6_NewFilter() m6_FreeFilter() m6_GetAreaFilter() m6_Error()

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