Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I think the fact that this form of dump doesn't contain foreign keys is even more extraordinary.

What's the point of having a dump format that you can't use to restore your database properly?

Does it have a health warning advising that it's not a proper dump?



Well, I've had issues with pg_dump's standard format. It can't be directly used to restore a db, one must manually set it to dump a .bak or something else.


Not sure what you refer to here. All pg_dump formats should work for restoring a database. The only flaw in pg_dump that I know of is the mess if you want to dump an entire cluster of databases but still have one file per database.


It contains the foreign key data, but not the constraint.

You get this:

    <field Field="course_id" Type="int(10)" Null="NO" Key="MUL"/>
But not this:

    CONSTRAINT `fk_courses_offered_class_details`
    FOREIGN KEY (`course_id`)
    REFERENCES `courses_offered` (`id`)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: