Archive for the ‘Database’ Category

MSSQL Express Scheduled Backups

The Express edition of SQL server lacks automated scheduled backup functionality.  The following script will back up your databases.  It retains them for 7 days but can be easily edited: Create a directory called c:\SQLBackup and go into it Create a backup.sql file: DECLARE @name VARCHAR(50) — database name DECLARE @path VARCHAR(256) — path for […]

Plesk SQL Queries

A few queries I put together to grab info from the Plesk database for troubleshooting: #FTP ACCOUNTS #———— SELECT account_id AS ‘ID’, login AS ‘USERNAME’, password AS ‘PASSWORD’, home AS ‘HOMEDIR’ FROM sys_users S, accounts A WHERE S.account_id = A.id; #MAIL ACCOUNTS #————- SELECT account_id AS ‘ID’, mail_name AS ‘USERNAME’, password AS ‘PASSWORD’, postbox as […]