title: Unable to return query output in Apex PL SQL expression
body: <p>I am trying to write a following PL/SQL function body for a dynamic action</p>
  
  <p>The purpose of dynamic action is to set value for text area based on input parameters. Way I am trying to do it, is that setting the value into variable for different options</p>
  
  <pre><code>declare
  
  P_NOTE varchar(100);  -- derive value
  P_WEBSERVER varchar(100);  -- derive name
  
  begin
  
  -- for getting the P_NOTE value
  select distinct note into P_NOTE  from port_mapping where PLATFORM = :P3_PLATFORM and VERSION = :P3_VERSION;
  
  -- for getting web server value
  select CONCAT(P_NOTE,CONCAT('https-',:P3_CLIENT)) into P_WEBSERVER from dual order by 1;
  
  if (:P3_PLATFORM = 'Apache') then
      return P_WEBSERVER;
  end if;
  
  end;
  </code></pre>
  
  <p>However I am getting error </p>
  
  <p>ORA-06550: line 15, column 5:
  PLS-00372: In a procedure, RETURN statement cannot contain an expression
  ORA-06550: line 15, column 5:
  PL/SQL: Statement ignored</p>
  
  <ol>
  <li>declare</li>
  <li>P_NOTE varchar(100);</li>
  <li>P_WEBSERVER varchar(100);</li>
  </ol>
  
  <p>I am not sure what I am missing.</p>