Created
May 11, 2017 12:42
-
-
Save a-sitnikov/0d9a278a128dd0adaf7e1b5c887cb6ef to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
SET v8="C:\1CData\8.3.9.2170_x64\bin\1cv8.exe" | |
SET cf="C:\1CData\release\1Cv8_2017-05-10.cf" | |
SET db=gr-rphost-01\PLPK_K3_ERP | |
SET logFile="N:\gr\dok\Users\AppData\sitnikov.a\1CData\update.log" | |
SET sqlServer=gr-sql | |
SET backup_sql="\\uniservice.local\net\gr\dok\Users\Desktops\sitnikov.a\Рабочий стол\scripts\backup_erp.sql" | |
if not exist %cf% goto filenotfound | |
echo Backup DB | |
sqlcmd -E -S %sqlServer% -i %backup_sql% | |
echo Load cf | |
%v8% CONFIG /S%db% /UC123321 /LoadCfg %cf% | |
echo Update DB | |
%v8% CONFIG /S%db% /UC123321 /UpdateDBCfg -Server /Out%logFile% | |
start "1cv8" %v8% ENTERPRISE /S%db% /UC123321 /CВыполнитьОбновлениеИЗавершитьРаботу | |
goto end | |
:filenotfound | |
echo File not found %cf% | |
:end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
backup_erp.sql