1 |
532
|
aaronmk
|
"PostgreSQL","MySQL","Comments"
|
2 |
687
|
aaronmk
|
,,"PostgreSQL-only features"
|
3 |
|
|
"^SET\b[^;]*;",,
|
4 |
713
|
aaronmk
|
"^(?:CREATE|ALTER) (?:AGGREGATE|SEQUENCE|TRIGGER|TYPE)\b[^;]*;",,
|
5 |
705
|
aaronmk
|
"(?s)^CREATE FUNCTION\b.*?(\$\w*\$).*?\1;",,
|
6 |
687
|
aaronmk
|
"^COMMENT\b[^;]*;",,
|
7 |
|
|
"^ALTER TABLE\b[^;]*\bSET DEFAULT nextval\([^;]*\)[^;]*;",,
|
8 |
|
|
"^CREATE\b[^;]*\bINDEX\b[^;]*\([^;]*\([^;]*;",,
|
9 |
706
|
aaronmk
|
",\n *CONSTRAINT\b.*\bCHECK\b.*?(?=,?$)",,
|
10 |
687
|
aaronmk
|
"\bDEFAULT \w*\(.*\)",,".* rather than .*? to allow nested ()"
|
11 |
|
|
"^(CREATE\b[^;]*\bINDEX\b[^;]*\b)USING \w+","\1",
|
12 |
|
|
"(?<=\bALTER TABLE )ONLY ",,
|
13 |
954
|
aaronmk
|
"\[\]",,"arrays"
|
14 |
687
|
aaronmk
|
,,"syntax changes"
|
15 |
537
|
aaronmk
|
"^--(?=\S)","\g<0> ",
|
16 |
561
|
aaronmk
|
"""([^""]*?)""","`\1`",
|
17 |
1231
|
aaronmk
|
"(?<=DEFAULT )(\d+|'[^']*')::\w+(?: [a-z]+)*","\1",
|
18 |
574
|
aaronmk
|
"(\d+|'[^']*')::(\w+(?: \w+)*)","CAST(\1 AS \2)",
|
19 |
687
|
aaronmk
|
,,"datatypes"
|
20 |
534
|
aaronmk
|
"\bserial( NOT NULL\b)?","int(11)\1 AUTO_INCREMENT",
|
21 |
687
|
aaronmk
|
"oid","int(11)",
|
22 |
1229
|
aaronmk
|
"integer","int(11)",
|
23 |
|
|
"boolean","int(1)",
|
24 |
687
|
aaronmk
|
"bytea","blob",
|
25 |
|
|
" with time zone\b",,
|
26 |
|
|
"fulltext","\g<0>__",
|
27 |
|
|
"\btimestamp\b(?: with time zone\b)?(?! NOT NULL\b)","\g<0> NULL",
|
28 |
1336
|
aaronmk
|
"^( *[a-z]\w* )(?!(?:double|int|text|timestamp)\b)\w+(?=\b[^;]*^\);)","\1text","custom types"
|