"peter.borissow@xxxxxxxxxxxxxxxx" <peter.borissow@xxxxxxxxxxxxxxxx> writes: > I guess the FDW is not "seeing" the default value for status and the bigserial sequence for the id column. Is there anyway around this? The idea is that you should attach default clauses to the foreign table definition. A remote serial column is a hard case for that, though, since you don't have ready access to the remote sequence. Because of that and some related examples, we don't currently expect that IMPORT FOREIGN SCHEMA should import the defaults that exist on the remote server. Using a view or trigger on the remote side is currently the best way around that for cases where you can't set up a suitable default on the local table. regards, tom lane