title: Postgres database restore with ignore errors
body: <p>I have created a postgres database backup using pg_dump command - which created <code>.sql</code> file</p>
  <p>I am trying to restore the database from this backup.  The original database name is called kstar and I want to restore it to a new database called rstar.</p>
  <p>I created the new database first by using <code>create database rstar</code>, and used the following command :</p>
  <pre><code>psql -U postgres rstar &lt; /home/ubuntu/bkup/kstar_Jun-13-2021.sql
  </code></pre>
  <p>The database is around 112 GB in size and it is critical for me to restore this database.  The above command creates all the tables and starts copying the data.  In one of the table which has a date column the data is in the backup for the date field is stored as <code>202</code> instead of <code>2021</code>, which throws the following error and stops the restoration.</p>
  <pre><code>ERROR:  invalid input syntax for type date: &quot;202&quot;
  CONTEXT:  COPY r_2332, line 368225818, column date: &quot;202&quot;
  </code></pre>
  <p>Is it possible to ignore this error, skip and continue with copying the database?</p>
  <p>The table schema for r_2332 is as follows:</p>
  <pre><code>                   Table &quot;public.r_2332&quot;
    Column   |       Type       | Collation | Nullable | Default 
  -----------+------------------+-----------+----------+---------
   site_id   | integer          |           |          | 
   date      | date             |           |          | 
   hour      | integer          |           |          | 
   reach     | integer          |           |          | 
   maid      | text             |           |          | 
   latitude  | double precision |           |          | 
   longitude | double precision |           |          | 
  Indexes:
      &quot;date_pkey&quot; btree (date)
      &quot;hour_pkey&quot; btree (hour)
      &quot;maid_pkey  &quot; btree (maid)
      &quot;reach_pkey&quot; btree (reach)
      &quot;site_id_pkey&quot; btree (site_id)
  </code></pre>