Revision 10439
Added by Aaron Marcuse-Kubitza over 11 years ago
my2pg | ||
---|---|---|
7 | 7 |
. "$(dirname "$(readlink -f "${BASH_SOURCE[0]}")")"/../lib/sh/util.sh |
8 | 8 |
|
9 | 9 |
sed \ |
10 |
-e 's/`/"/g' \ |
|
10 | 11 |
-e 's/ UNIQUE KEY ("[^"]*")/ \/*CONSTRAINT \1 *\/UNIQUE/g' \ |
11 | 12 |
-e 's/ UNIQUE KEY/ UNIQUE/g' \ |
12 | 13 |
-e 's/^ ((CONSTRAINT "[^"]*" )?((FULLTEXT|FOREIGN) )?KEY .*[^,])(,?)$/ \/*\1*\/CHECK (true)\5/' \ |
Also available in: Unified diff
bin/my2pg: replace MySQL ` quotes with " quotes to support exports that were generated without ANSI_QUOTES mode. (this replacement only applies to schema exports, not data.) ANSI_QUOTES is only available with mysqldump --compatible modes that also include NO_TABLE_OPTIONS, which omits important table options such as comments. in particular, these comments are part of schemas/VegCore/VegCore.ERD.mwb but were not being included in VegCore.my.sql.