>>Is there a way to recycle deleted records?
>>
>>If so then that might preclude the need to zap or pack (or other workarounds)
>>
>>TIA
>>Jere Dorough
>
>You can, but you have to do it yourself.
>Something along the lines of
>
>
>cDel= SET('DELETED')
>SET DELETED OFF
>LOCATE FOR DELETED()
>IF FOUND()
> * Recycle this record
> BLANK()
> RECALL()
>ELSE
> * No deleted, so create new
> APPEND BLANK
>ENDIF
>SET DELETED (m.cDel)
>
>
>
>I havnt tested the above code, but I know it is something like that, might need to add some more security etc.
Small correction: BLANK is a command, not a function.
I did something similar once. With an OOP-framework (designed by yourself, or bought), you would want to integrate this into the generic commands that add a record.
Please note that this method will not completely avoid the need to PACK if you have memo fields!
What I
currently do is simply program the PACK for some time around midnight.
Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)