I need to have a consistently updated geodatabase that will go offline in Collector. I am open to new ways to do this. What I have been working on is below. Our environment: SQL Server 2012, ArcGIS 10.2.1, ArcGIS Server 10.2.2., Collector on iOS.
Our production sde database does not meet the requirements for offline use so a new database has been created solely for the offline purpose, "OfflineDBProd". Since the script we use to update the offline database takes a few hours to run and in an effort to have OfflineDBProd down for as little time as possible, a staging database, "OfflineDBTemp," was created on a different server instance for this purpose. In reality, both OfflineDBProd and OfflineDBTemp have the same name but to be less confusing here I have them named differently.
A script is used to, daily, copy and transform data from the production sde database to OfflineDBTemp. Contents of OfflineDBTemp are deleted and is refilled with the latest data, archiving enabled, and global IDs added, among other things.
A different script backs up OfflineDBTemp, copies the .bak file to the production server, and OfflineDBProd is restored with OfflineDBTemp.
To me it seems like the only changes in the OfflineDBProd (as viewed from the Collector app) would be the edits made in the production sde database the day before. Collector will download a fresh copy of the data but will not sync the following day, after the script and restore was carried out. The error message is:
Invalid or missing input parameters. Replica with this GUID does not exist on the server.