title: ERROR: relation "students" already EXISTS
body: <p>When I am executing this query:</p>
  
  <pre><code>CREATE TABLE public.students (
    id INTEGER PRIMARY KEY NOT NULL DEFAULT NEXTVAL('students_id_seq'::regclass),
    first_name CHARACTER VARYING(20) NOT NULL,
    last_name CHARACTER VARYING(20) NOT NULL,
    major CHARACTER VARYING(20) NOT NULL
  );
  CREATE UNIQUE INDEX "Students_ID_uindex" ON students USING BTREE (id);
  
  SELECT * FROM public.students;
  </code></pre>
  
  <p>I get the following error:</p>
  
  <pre><code>[2016-03-12 22:16:54] Run postgres.public.students [PostgreSQL - postgres@localhost]
  [2016-03-12 22:16:54] Connecting TO PostgreSQL - postgres@localhost...
  CREATE TABLE public.students (
    id INTEGER PRIMARY KEY NOT NULL DEFAULT NEXTVAL('students_id_seq'::regclass),
    first_name CHARACTER VARYING(20) NOT NULL,
    last_name CHARACTER VARYING(20) NOT NULL,
    major CHARACTER VARYING(20) NOT NULL
  )
  [2016-03-12 22:16:54] [42P07] ERROR: relation "students" already EXISTS
  CREATE UNIQUE INDEX "Students_ID_uindex" ON students USING BTREE (id)
  [2016-03-12 22:16:54] [42P07] ERROR: relation "Students_ID_uindex" already EXISTS
  SELECT * FROM public.students
  [2016-03-12 22:16:54] Executed IN 14ms ms
  
  [2016-03-12 22:16:54] Summary: 3 OF 3 statements executed, 2 failed IN 68ms (338 symbols IN file)
  </code></pre>
  
  <p>I have made the table using DataGrip generate:
  <a href="https://i.stack.imgur.com/6MqYc.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/6MqYc.png" alt="enter image description here"></a></p>
  
  <p>Any idea what am I doing wrong?</p>
  
  <p><a href="https://i.stack.imgur.com/uodsB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uodsB.png" alt="enter image description here"></a></p>
  
  <p>UPDATE: Just to clarify my question, when I first run the code with a new table name, I get now error but when I run it again I get the above error. How can this be fixed?</p>
  
  <p><a href="https://i.stack.imgur.com/QyPC8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/QyPC8.png" alt="enter image description here"></a></p>