KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Controlling the Number of Logs Saved
PRODUCT: 4D | VERSION: 15 | PLATFORM: Mac & Win
Published On: December 17, 2015

In 4Dv15, the number of logs saved can be controled by code using the SET DATABASE PARAMETER command with the Circular log limitation (90) selector. By default, unless set through other means, all logs will be saved. By passing in an interger value for the second parameter, the database will only save that value of logs, for all logs. When the limit is reached, the database will automatically delete the oldest log after the creation of the new log.

This setting will affect the following logs:

  • Request Logs

  • Debug Logs

  • Event Logs

  • Web Request Logs

  • Web Debug Logs

Example:
SET DATABASE PARAMETER(Circular log limitation;50)

The code above will set it so that when any set of logs reach 51, the oldest one will be deleted.