Does anyone have an example of a SQL statement I could use to create a nightly backup of one SQL database, make it a copy-only backup, write it to a file with the date/time as the backup filename?
I see the example
BACKUP DATABASE database_name TO <backup_device> … WITH COPY_ONLY …
in the SQL 2005 help. But I don't know how to combine that with automatically putting the date/time in the TSQL.