title: Error in open-for-using statement
body: <p><em>im trying the dynamic cursor concept in my stored procedure in oracle</em> i used the stmt as below:</p>
  
  <pre><code>OPEN d for
              'select datetime,'|| v_paramname ||',tt from datasource where '|| v_vrformula ||' and  feederid=cast('||v_meterid||',varchar2(6)) and datetime&gt;=:v_timeperiod' using v_timeperiod;
      LOOP
      FETCH d INTO V_dateval,V_value,V_dataid;
      EXIT WHEN d%NOTFOUND;
      INSERT INTO pseb.validationfailureaudit (MeterID,RuleID,DataType,Value,Dataid, TimePeriod,EditedValue,EditedTimePeriod,paramname) VALUES  (V_meterid,V_ruleid,V_datatype,V_value ,V_dataid,V_dateval,null, null,V_paramname);
      V_length:=V_length+1;
      END LOOP;
  CLOSE d;
  </code></pre>
  
  <p>I m getting <strong>missing keyword</strong> error in <strong>open</strong> statement.</p>
  
  <p>Please help me to solve it.</p>