> > I can't really make this an FK. I can (and probably will) put this into a >> trigger. Although it seems like an extra layer of wrapping just to call a >> function. I'm curious if there's any conceptual reason why constraints >> couldn't (as an option) be restored after all the data is loaded, and >> whether there would be any negative consequences of that? I could see if >> your data still didn't pass the CHECKs, it's already loaded. But the >> constraint could then be marked not valid? >> > > Not sure why just know that if I stay within the guidelines it works, if I > do not its does not work:) > > That's fair enough, leaving aside the curiosity part. Usually though the things you can't do just aren't allowed. It's easier to overlook something that you shouldn't (but can) do!
> See that, but in your scenario you wanted to create a 'scratch' database > so you are back to a user with privileges. > Yeah, I was thinking pg_dump could just conjure it up in the ether (and then discard it), but I can see that doesn't really work. Basically, if you have no way to test your backup/restore procedure before > hand you are flying blind. > > In this case, we had tested the restore part. But then we changed the DB in a way that made it stop working. Good reminder to retest that periodically! Ken -- AGENCY Software A Free Software data system By and for non-profits *http://agency-software.org/ <http://agency-software.org/>* *https://agency-software.org/demo/client <https://agency-software.org/demo/client>* ken.tan...@agency-software.org (253) 245-3801 Subscribe to the mailing list <agency-general-requ...@lists.sourceforge.net?body=subscribe> to learn more about AGENCY or follow the discussion.