Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Paulo V C Medeiros
Merge SQLite DBs
Commits
8291c911
Commit
8291c911
authored
Oct 15, 2020
by
Paulo V C Medeiros
Browse files
Add merge_using_dump.sh
parent
d6d3c40d
Changes
1
Hide whitespace changes
Inline
Side-by-side
merge_using_dump.sh
0 → 100755
View file @
8291c911
#!/bin/bash
rm
-f
dump.sql output_with_dump.db
for
f
in
"
$@
"
;
do
sqlite3
-vfs
unix-none
$f
".dump"
|
sed
-e
"s/CREATE TABLE/CREATE TABLE IF NOT EXISTS/"
|
sed
-e
"s/CREATE INDEX/CREATE INDEX IF NOT EXISTS/"
>>
dump.sql
done
sqlite3
-vfs
unix-none output_with_dump.db
".read dump.sql"
rm
-f
dump.sql
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment