Very new to SQL Server. I'm trying to bring a backup from one our clients Windows 2012 Server Install to our Linux Install. We have the site working perfectly on Linux, but can't seem to do an arbitrary DB dump to get new data. They are running SQL Server 2012 Express (I'm assuming because it didn't have "Maintenance Plans" under the Management tab of the object Explorer)
Or in transact SQL:
BACKUP DATABASE [YourDB] TO [YourDB_backup] WITH NOFORMAT, NOINIT, NAME = N'YourDB-Full Database Backup', SKIP, NOREWIND, NOUNLOAD, STATS = 10 GO
When I pulled this down to my Linux server it didn't have updated information (that was created 5-6 hours earlier). Why is this?
To ensure I wasn't making a mistake I deleted the entried DB on my Linux machine with:
USE master; GO DROP DATABASE YourDB; GO
And then uploading it again as dictated here:
RESTORE DATABASE YourDB FROM DISK = '/var/opt/mssql/backup/YourDB.bak' WITH MOVE 'YourDB' TO '/var/opt/mssql/data/YourDB.mdf', MOVE 'YourDB_Log' TO '/var/opt/mssql/data/YourDB_Log.ldf' GO
Interestingly, their backup task that runs at midnight does have the new information, but I can't see where that task occurs to compare the script.