From: Bruce Momjian Date: Tue, 6 Mar 2001 22:46:50 +0000 (+0000) Subject: Update my2pg, new version. X-Git-Url: http://waps.l3s.uni-hannover.de/gitweb/?a=commitdiff_plain;h=810412d3c0d443e342d78e7ad86cfb5692ab8b6c;p=users%2Fbernd%2Fpostgres.git Update my2pg, new version. --- diff --git a/contrib/mysql/my2pg.pl b/contrib/mysql/my2pg.pl index a160e80104..baf300de63 100755 --- a/contrib/mysql/my2pg.pl +++ b/contrib/mysql/my2pg.pl @@ -46,8 +46,13 @@ # # $Log: my2pg.pl,v $ +# Revision 1.18 2001/03/06 22:25:40 fonin +# Documentation up2dating. +# # Revision 1.17 2001/03/04 13:01:50 fonin -# Fixes to make work it right with MySQL 3.23 dumps. Tested on mysqldump 8.11. Also, AUTO_INCREMENT->SERIAL fields no more have DEFAULT and NOT NULL definitions. +# Fixes to make work it right with MySQL 3.23 dumps. Tested on mysqldump 8.11. +# Also, AUTO_INCREMENT->SERIAL fields no more have DEFAULT and NOT NULL +# definitions. # # Revision 1.16 2001/02/02 08:15:34 fonin # Sequences should be created BEFORE creating any objects \nthat depends on it. @@ -105,7 +110,7 @@ if($opts{n} ne '') { $|=1; print("------------------------------------------------------------------"); -print("\n-- My2Pg \$Revision: 1.3 $ \translated dump"); +print("\n-- My2Pg \$Revision: 1.4 $ \translated dump"); print("\n--"); print("\n------------------------------------------------------------------"); @@ -127,7 +132,7 @@ $libtypename.='/libtypes.so'; # push header to libtypes.c open(LIBTYPES,">$libtypesource"); print LIBTYPES "/******************************************************"; -print LIBTYPES "\n * My2Pg \$Revision: 1.3 $ \translated dump"; +print LIBTYPES "\n * My2Pg \$Revision: 1.4 $ \translated dump"; print LIBTYPES "\n * User types definitions"; print LIBTYPES "\n ******************************************************/"; print LIBTYPES "\n\n#include \n"; @@ -639,7 +644,7 @@ close(LIBTYPES); open(MAKE,">Makefile"); print MAKE "# -# My2Pg \$Revision: 1.3 $ \translated dump +# My2Pg \$Revision: 1.4 $ \translated dump # Makefile # @@ -710,7 +715,7 @@ my2pg - MySQL -> PostgreSQL dump conversion utility. =head1 SYNTAX - mysqldump db | ./my2pg.pl [-n] > pgsqldump.txt + mysqldump db | ./my2pg.pl [-n] > pgsqldump.sql vi libtypes.c make psql database < pgsqldump.txt @@ -718,11 +723,7 @@ where =over 4 -=item B - -- mysqldump utility output, - -=item B +=item B - file suitable for loading into PostgreSQL. @@ -756,6 +757,11 @@ interferension with reserved words; =item Converting +AUTO_INCREMENT fields to SERIAL. Actually, creating the sequence and +setting default value to nextval('seq'), well, you know :) + +=item Converting + KEY(field) to CREATE INDEX i_field on table (field); =item The same @@ -764,7 +770,7 @@ for UNIQUE keys; =item Indices -are creating AFTER rows insertion (to speed up the load); +are creating AFTER rows insertion (to speed up the load); =item Translates '#' @@ -809,7 +815,7 @@ for Makefile. =head1 BUGS -This program is very beta and extremely bugsome. +This program is still beta. Testers wanted. Known bugs are: =over 4 @@ -839,8 +845,8 @@ include path, you need to check it before compiling. =head1 AUTHORS -B<(c) 2000 Maxim V. Rudensky > -B<(c) 2000 Valentine V. Danilchuk > +B<(c) 2000 Maxim V. Rudensky (fonin@ziet.zhitomir.ua)> +B<(c) 2000 Valentine V. Danilchuk (valdan@ziet.zhitomir.ua)> =head1 LICENSE