[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 DBCOMMITALL()
 Flush pending updates in all work areas
------------------------------------------------------------------------------
 Syntax

     DBCOMMITALL() --> NIL

 Returns

     DBCOMMITALL() always returns NIL.

 Description

     DBCOMMITALL() causes all pending updates to all work areas to be written
     to disk.  It is equivalent to calling DBCOMMIT() for every occupied work
     area.

     For more information, refer to DBCOMMIT() and the COMMIT command.

 Notes

     .  DBCOMMITALL() uses DOS interrupt 21h function 68h to perform
        the solid-disk write.  It is up to the network operating system to
        properly implement this request.  Check with the network vendor to
        see if this is supported.

 Examples

     .  The following example writes all pending updates to disk:

        cLast := "Winston"
        //
        DBUSEAREA( .T., "DBFNTX", "Sales", "Sales", .T. )
        DBSETINDEX( "SALEFNAM" )
        DBSETINDEX( "SALELNAM" )
        //

        DBUSEAREA( .T., "DBFNTX", "Colls", "Colls", .T. )
        DBSETINDEX( "COLLFNAM" )
        DBSETINDEX( "COLLLNAM" )

        DBSELECTAREA( "Sales" )      // select "Sales" work area

        IF ( Sales->(DBSEEK(cLast)) )
           IF Sales->( DELETED() ) .AND. Sales( RLOCK() )
              Sales->( DBRECALL() )
              ? "Deleted record has been recalled."
           ENDIF
        ELSE
           ? "Not found"
        ENDIF
        //
        // processing done, write updates to disk and close
        DBCOMMITALL()
        DBCLOSEALL()
        QUIT

 Files   Library is CLIPPER.LIB.


See Also: CLOSE COMMIT DBCLOSEALL() DBCOMMIT() DBUNLOCK()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson