SCM

Forum: bugs

Monitor Forum | Start New Thread Start New Thread
RE: USE dbname misses newline [ reply ]
By: Kim Bisgaard on 2008-01-04 13:23
[forum:1002984]
No, I used MySQL Aministrator an official MySQL tool for windows and linux to make the backup.

RE: USE dbname misses newline [ reply ]
By: joe speigle on 2008-01-04 13:09
[forum:1002982]
once again, is this standard mysqldump?

USE dbname misses newline [ reply ]
By: Kim Bisgaard on 2008-01-03 09:45
[forum:1002969]
This input:
CREATE DATABASE IF NOT EXISTS oceanDB;
USE oceanDB;
CREATE TABLE `oceanDB`.`archiveSeaObs` (

Gives this output:
CREATE DATABASE IF NOT EXISTS oceanDB;
\c oceanDB
CREATE TABLE oceanDB.archiveSeaObs (

The fix is this simple patch:
--- mysql2pgsql.perl~ 2008-01-03 09:29:23.216820000 +0100
+++ mysql2pgsql.perl 2008-01-03 10:17:33.175733000 +0100
@@ -320,7 +320,7 @@
# doh! we hope all dashes and special chars are caught by the regular expressions :)
}
if (/^\s*USE\s*([^;]*);/) {
- print OUT "\\c ". $1;
+ print OUT "\\c ". $1 ."\n";
next;
}
if (/^(UN)?LOCK TABLES/i || /drop\s+table/i ) {


Regards,
Kim

Powered By FusionForge