Skip to content

Commit

Permalink
Fix pg_dump quoting text column type
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan Wrobel committed Nov 1, 2013
1 parent 37b4483 commit fcdbb07
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pg2mysql.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ function pg2mysql(&$input, $header=true)
$line=str_replace(" boolean"," bool",$line);
$line=str_replace(" bool DEFAULT true"," bool DEFAULT 1",$line);
$line=str_replace(" bool DEFAULT false"," bool DEFAULT 0",$line);
$line=str_replace("` `text`","` text",$line); // fix because pg_dump quotes text type for some reason
if(ereg(" character varying\(([0-9]*)\)",$line,$regs)) {
$num=$regs[1];
if($num<=255)
Expand Down

0 comments on commit fcdbb07

Please sign in to comment.