Syntax
DbAppend( [lReleaseRecLocks] ) --> NILArguments
lReleaseRecLocks
Releases the current record locks before appending when true.
Return value
NIL.
Description
DbAppend() adds a blank record to the table in the current work area and makes it the current record. The new record can then be filled with FieldPut().
Notes
A read-only work area or an I/O failure raises an error. The optional flag defaults to false.
Example
PROCEDURE Main()
DbCreate( "append_demo.dbf", { { "NAME", "C", 12, 0 } } )
DbUseArea( .T., , "append_demo.dbf", "Demo" )
DbAppend()
FieldPut( 1, "Anna" )
DbCommit()
QOut( "Records: " + LTrim( Str( RecCount() ) ) )
QOut( "Name: " + RTrim( FieldGet( 1 ) ) )
DbCloseArea()
FErase( "append_demo.dbf" )
RETURNOutput