- Service Names and Paths: Sets variables for the service names and paths to their respective executables.
- Check Services: Uses sc query to check if each service is running.
- Toggle Services: If one service is running, it stops that service and starts the other. If neither service is running, it starts the first service by default.
- Execution: Uses sc stop and sc start to manage the services.
- Pause: Pauses the script at the end so you can see the output.
Save this script with a .bat extension, and run it with administrator privileges to toggle the MariaDB services.