On 24 Mar 2014, at 5:32, Rajeev rastogi <rajeev.rastogi@xxxxxxxxxx> wrote: > On 21st March 2014, Ashmita Jain Wrote: > > >It is taking date as an empty string. > >Try defining the empty field as ‘\N’ in your source file. > > ‘\N’ in copy source file always results into an empty string (unless something written in new line), which is correct only. > So COPY from such source file will always fail except for the case if the column data-type is string. You appear to be confusing \N with \n. Those are very different escape codes; the second means new line, while the first means NULL. Alban Hertroys -- If you can't see the forest for the trees, cut the trees and you'll find there is no forest. -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general