Backs up MSSQL databases and truncates the log

This script backs up MSSQL databases from a machine that has the SQL SMO components installed (install SQL Management studio or the SMO SDK to get these).

It also gets the SQL service account name, and checks whether that user account has read/write privileges to the destination folder. This can fail though if PS Remoting or Script Execution is disabled on the SQL server, you have the option to ignore this check and carry on.