title: Error when creating view with union statement in pl sql
body: <p>I would like to create a view with a union of parts of two tables. </p>
  
  <p>Hereafter is the statement:</p>
  
  <pre><code>create view "test" AS 
  select 
  ppt.reportingtime reportingtime,
  ppt.currency currency,
  ppt.channelid channelid,
  ppt.transactiontype ttype
  FROM preprocessortransactions ppt
  union
  select 
  bm.balancetype balancetype
  from balancemovements bm
  </code></pre>
  
  <p>The error message I get is the following:</p>
  
  <blockquote>
    <p>Error starting at line 1 in command: </p>
    
    <p>create view "test" AS  SELECT<br>
        ppt.reportingtime reportingtime, 
        ppt.currency currency, 
        ppt.channelid channelid, 
        ppt.transactiontype ttype 
        FROM 
        preprocessortransactions ppt
        union
        select
        bm.balancetype balancetype from balancemovements bm </p>
    
    <p>Error at Command Line:1 Column:22 Error report: SQL Error: ORA-01789: query block has incorrect number of result columns 01789. 00000 -  "query block has incorrect number of result columns"
        *Cause:<br>
        *Action:</p>
  </blockquote>
  
  <p>I am pretty new to pl sql and I can't figure out the meaning of the reported error.</p>
  
  <p>I also tried with listing the column names in between brackets before the first AS operator with no success.</p>