Last active
June 24, 2016 13:27
-
-
Save geobabbler/9816088 to your computer and use it in GitHub Desktop.
Windows batch file to merge MBTiles database. Based on 'patch' (https://github.com/mapbox/mbutil/blob/master/patch)
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
REM based on 'patch' here: https://github.com/mapbox/mbutil/blob/master/patch | |
@ECHO OFF | |
REM goto CATCH | |
REM %1 = source database | |
REM %2 = destination database | |
echo PRAGMA journal_mode=PERSIST;PRAGMA page_size=80000;PRAGMA synchronous=OFF;ATTACH DATABASE '%1' AS source;REPLACE INTO map SELECT * FROM source.map;REPLACE INTO images SELECT * FROM source.images;REPLACE INTO grid_data SELECT * FROM source.grid_data; | "C:\spatialite3\bin\sqlite3.exe" %2% | |
GOTO FINALLY | |
:CATCH | |
echo there was an error | |
:FINALLY |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment