Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>The declaration of <code>P_INSERT_TABLE2</code> is invalid. You can't have 5 input parameters all named <code>pi_C4</code>. Since you're not getting a compilation error creating that procedure, I'll guess that this was a bug that was introduced posting the question here rather than something that is actually in the code.</p> <p>According to the declaration of <code>P_INSERT_TABLE2</code>, the procedure takes 7 input parameters and one output parameter. In the code you posted, you appear to be passing in 7 input parameters but you are not passing in a variable for the output parameter. It appears that you need something like</p> <pre><code>P_INSERT_TABLE2(pi_id, record_po.C3, record_po.C4, record_po.C5, record_po.C6, record_po.C7, to_char(record_po.C8, 'DD/MM/YYYY'), &lt;&lt;some local variable for the output parameter&gt;&gt; ); </code></pre> <p>Beyond the syntax errors, I am extremely dubious when I see someone taking a perfectly good <code>DATE</code>, casting it to a string, and then passing that to a procedure. That implies either that <code>P_INSERT_TABLE2</code> is going to turn around and convert the string back to a date, which means that you're doing extra work and have introduced additional points where the conversions can fail, or that you are going to write the string representation of a date to a table. Neither of these implications are good. </p> <p>I am also highly dubious of any procedure that has an <code>OUT</code> parameter named <code>pMessage</code>. That tends to imply that you're not using exceptions properly and that you're passing an error message back rather than throwing an exception if your code encounters an error. That virtually always leads to much more brittle code that is much more difficult to debug than when you use proper exceptions.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload