The SELECT clauses select all the columns from the tables listed in the FROM clauses. The UNION set operator concatenates the query results that are produced by the two SELECT clauses. UNION orders the result by IdNum.
proc sql;
   create table proclib.newpay as
      select * from proclib.paylist
      select * from proclib.paylist2;