fordfrog / apgdiff

Another PostgreSQL Diff Tool
http://www.apgdiff.com
MIT License
355 stars 138 forks source link

Runtime exception #176

Closed gregfaulk closed 8 years ago

gregfaulk commented 8 years ago

I'm getting the following error:

Exception in thread "main" java.lang.RuntimeException: Cannot find object 'asset_country_weight' for statement 'ALTER TABLE asset_country_weight OWNER TO asi;'. at cz.startnet.utils.pgdiff.parsers.AlterTableParser.parse(AlterTableParser.java:72) at cz.startnet.utils.pgdiff.loader.PgDumpLoader.loadDatabaseSchema(PgDumpLoader.java:180) at cz.startnet.utils.pgdiff.loader.PgDumpLoader.loadDatabaseSchema(PgDumpLoader.java:236) at cz.startnet.utils.pgdiff.PgDiff.createDiff(PgDiff.java:29) at cz.startnet.utils.pgdiff.Main.main(Main.java:39)

I'm attaching the two DDL files and the command line used to run apgdiff in the attached ZIP file. reproduce_bug.zip

f-ewald commented 8 years ago

Same for me with a different scheme:

Exception in thread "main" cz.startnet.utils.pgdiff.parsers.ParserException: Cannot find column 'id' in table 'ir_act_client'
at cz.startnet.utils.pgdiff.parsers.AlterTableParser.parseAlterColumn(AlterTableParser.java:266)
at cz.startnet.utils.pgdiff.parsers.AlterTableParser.parse(AlterTableParser.java:79)
at cz.startnet.utils.pgdiff.loader.PgDumpLoader.loadDatabaseSchema(PgDumpLoader.java:180)
at cz.startnet.utils.pgdiff.loader.PgDumpLoader.loadDatabaseSchema(PgDumpLoader.java:236)
at cz.startnet.utils.pgdiff.PgDiff.createDiff(PgDiff.java:29)
at cz.startnet.utils.pgdiff.Main.main(Main.java:39)

Any solution in sight?

avbasov commented 8 years ago

@gregfaulk This bug was fixed with PR #178. @f-ewald You've got the old bug #106. Can you provide your diffs for tests.