CALL (239) 961-8285
ENDURTECH
  • Web Services
    • Web Design
      • Design and Development
      • Web Consulting and Tutoring
      • Hosting and Maintenance
      • Project Portfolio
    • Media
      • Photo and Audio, Video Editing
      • Social Media Management
      • All Web Related Services
    • Marketing
      • Digital Marketing and Branding
      • Search Engine Optimization
    • Client Portal
      • Remote Web Support
      • Web Services Payment
      • Scheduled Payments
  • Tech Support
    • Services
      • Computer Support and Repair
      • Data Backup and Recovery
      • Computer Security, Virus Removal
      • Computer Networking Support
      • Computer Consulting & Tutoring
      • All Technology Related Services
    • Blockchain
      • Blockchain Technology
      • Cryptocurrency Articles
    • Client Portal
      • Remote PC Support
      • Remote Monitoring & Management
      • Tech Services Payment
  • Articles
  • About
  • Talk to Me
  • Menu Menu

Limit Number of Sage Timeslips Database Backup Files

Linux, Raspberry Pi, Technology Support

Sage Timeslips offers a Scheduled Backup feature which will help automate the Timeslips database backup process. However, the current Scheduled Backup feature uses the Windows Task Scheduler to execute a Windows batch file which does not include any code limiting the number of backups it creates. I tried contacting Sage support about this but they have no solution at the present moment. Perhaps by the time you are reading this they have one.

In this article I cover what I did to limit the number of Sage Timeslips database backup copies stored within the Backups directory of my client’s computer. Note that I do not work for nor am I in any way affiliated with the Sage company. The information herein is for my personal use only so that I can recall what I did should the need arise. You can hire me to assist you with your Timeslips database backups remotely by contacting me.

If you do not know what you are doing with Windows batch files you may inadvertently and permanently delete important system files or lose vital data. Especially if you fail to properly backup your data and computer. You’ve been warned!

 

Use the Sage Timeslips Backup Batch File to Limit Backup Files

To limit the number of Sage Timeslips database backups that are stored on the computer I added a single line of code to the default Timeslips backup batch file (Timeslips Backup.bat).

That default batch backup file was generated using the 2021 Sage Timeslips Scheduled Backup feature with the “Append date and time to the filename” checkbox selected.

This checks for any files (not subdirectories) that are older than 8 days. If it finds any, they are permanently deleted. Since my database backs up every day, I will effectively be storing one-weeks worth of Sage Timeslips database backups via this method.

Syntax Code

forfiles /p “C:\path\to\dir” /s /m *.* /D -<number of days> /C “cmd /c del @path”

Syntax Code Explanation

  • FORFILES – This command allows you to execute a command on each file.
  • /p “C:\path2dir” – This is the path to the directory where the files exist that, in my case, I want wish to limit.
    • If the path is not specified, it will default to the current folder where the batch file is at (be careful!).
  • /s – This flag will ensure the inclusion of any sub-folders.
  • /m – This flag matches the specified wildcard, *.* means ALL FILES regardless of file extension. For my purpose I only want to select the Timeslips database backup files which is why I am using the wildcard plus TBU file extension: *.TBU
  • /D – This flag specifies a date.
    • Examples:
      • for files older than 30 days use /D “-30”
      • for files new than 30 days use /D “+30”
    • You can specify a date using DDMMYY or -DDMMYY
      • Example: /D -01/01/2022
  • /C – This instructs the command to execute for each file, in this case I specified “cmd /c del @path”
  • @path – This is the full path, including name. This is done automatically.
    • To bypass the “Are you sure” prompt which will also pause the deletion of any files until you provide confirmation, use: del /F /Q @path

Syntax Code Used

Below is the code that I added to the end of my Timeslips Backup.bat batch file which is called upon every evening via the Windows Task Scheduler.

My backups are located at C:\Timeslips\Backups because I am sharing this folder in my root C: directory with other computers. I only want 30 days (one month) worth of Timeslips database backups so I used -30. I also made sure to only look for .TBU files and I used the /F and /Q flags just before @path to prevent the file deletion confirmation box from appearing. Otherwise, if no one is around to click the OK button on the file deletion confirmation box it won’t delete those old (beyond 30 days) database backup files.

forfiles /p “C:\TimeslipsData\Backups” /m *.TBU /D -30 /C “cmd /c del /F /Q @path”

Syntax Code Variations

Though I did not do this, I could have used and set variables at the top of the batch file. For example, there was a “BACKUPPATH” variable that I could have used so I wouldn’t have to manually set the “forfiles” path. I could have created a “DAYS” variable as well as “FEXT” (file extension) variable to make future changes easier.

SET DAYS=-30
SET FEXT=*.TBU

CODE NOT TESTED NOR CONFIRMED BELOW! DO NOT USE!!! Simply posted for informational purposes only!

forfiles /p “%BACKUPPATH%” /m %FEXT% /D “%DAYS%” /C “cmd /c del /F /Q @path”

 

Conclusion

I welcome your thoughts, questions or suggestions on my article on limiting the number of Sage Timeslips database backup copies.

You may support my work by sending me a tip using your Brave browser or by sending me a one time donation using your credit card.

Let me know if you found any errors within my article or if I may further assist you by answering any additional questions you may have.

 

March 5, 2022
Share this entry
  • Share on Facebook
  • Share on X
  • Share on WhatsApp
  • Share on LinkedIn
  • Share on Reddit
  • Share by Mail
https://endurtech.com/wp-content/uploads/2022/03/sage-timeslips-database-backup-file-limit-batch.jpg 512 512 Manny https://endurtech.com/wp-content/uploads/2018/04/endurtech-logo.png Manny2022-03-05 21:09:482022-03-07 13:30:53Limit Number of Sage Timeslips Database Backup Files
Search Search

CONNECT WITH US

This field is for validation purposes and should be left unchanged.
Engagement*

Want to say, "thanks"?
Leave me a review on Facebook and/or Google.

You can send me a tip using your Brave browser. Get Brave!

Only used to send you a receipt.
Include a Message
Popular
  • Windows Logo
    Second Monitor on Windows 10 Resets After SleepJuly 2, 2020 - 6:30 am
  • Windows Logo
    How to Disable the F1 Help Key in Windows 10April 15, 2021 - 2:40 pm
  • Cortana Logo
    How to Disable Microsoft’s CortanaApril 6, 2021 - 9:00 am
  • Firefox Logo
    How to Remove All Passwords from Lockwise in FirefoxMarch 26, 2020 - 11:00 am
Recent
  • How to Fix Brother BrLog Errors
    How to Fix Brother BrLog ErrorsAugust 24, 2026 - 10:55 am
  • How to block Facebook crawler
    List of Spider Crawlers to BlockAugust 10, 2026 - 9:20 am
  • Brave Browser Logo
    How to Fix the “Not Secure” Address Bar Err...July 20, 2026 - 12:48 pm
  • Linkpull Extension By Endurtech
    LinkPull Extension, Grab Any File From a URLJuly 7, 2026 - 7:35 pm

STAY IN TOUCH

ENDURTECH Web Design Company Naples, Florida

Endurtech GitHub ProfileEndurtech YouTube ChannelEndurtech LinkedIn ProfileEndurtech Facebook Page

5 Star Google Review for Endurtech - Naples Web Design Company

Learn More & Connect

Search Search
ENDURTECH Logo
Endurtech GitHub ProfileEndurtech YouTube ChannelEndurtech LinkedIn ProfileEndurtech Facebook Page

5 Star Google Review for Endurtech - Naples Web Design Company

Latest Articles

  • How to Fix Brother BrLog Errors
    How to Fix Brother BrLog ErrorsAugust 24, 2026 - 10:55 am
  • How to block Facebook crawler
    List of Spider Crawlers to BlockAugust 10, 2026 - 9:20 am
  • Brave Browser Logo
    How to Fix the “Not Secure” Address Bar ErrorJuly 20, 2026 - 12:48 pm
  • Linkpull Extension By Endurtech
    LinkPull Extension, Grab Any File From a URLJuly 7, 2026 - 7:35 pm

Recent Projects

  • Jewelry Website Gems of Note
    Gems of NoteNovember 15, 2019 - 10:16 pm
  • Gift Store Facebook Business Page Cover Video
    Gift Store Facebook Business Page Cover VideoApril 13, 2019 - 3:58 pm
  • Toledo Yoga BrandBot Footer Integration
    Toledo YogaApril 9, 2019 - 7:26 am
  • Lawyer Association Website with Member Portal
    National Employment Lawyers Association, Florida ChapterFebruary 26, 2019 - 8:00 am

Business Details

Mondays - Fridays
9:00 am - 5:00 pm
Eastern Standard Time
After hours by appointment

SUPPORT PHONE

(239) 961-8285

MAILING ADDRESS

59 Logan Ln.
Lynchburg, VA 24502

Copyright © 2026 ENDURTECH ® All Rights Reserved. Legal
Link to: Clear Windows Defender Protection History Link to: Clear Windows Defender Protection History Clear Windows Defender Protection HistoryWindows Logo Link to: Download New Tab Background Images from Brave Link to: Download New Tab Background Images from Brave Brave Browser LogoDownload New Tab Background Images from Brave
Scroll to top Scroll to top Scroll to top