title: The number specified in exact fetch is less than the rows returned: is that impossible
body: <p>I have defined the following procedure in PL/SQL:</p>
  
  <pre><code>CREATE OR REPLACE PROCEDURE deleteFromStudyCase(studycase_id IN NUMBER)
  IS
     VAL_CARRIER_ID_GLOBAL  NUMBER(19,0);
     EST_OBJ_ID_GLOBAL      NUMBER(19,0);
     INVEST_TASK_ID_GLOBAL  NUMBER(19,0);
  BEGIN
  
  -- Fill the variables
  SELECT IT.ID into INVEST_TASK_ID_GLOBAL
    FROM T_INVESTIGATIONTASK IT
    WHERE IT.STUDYCASE_ID = studycase_id;
  
  SELECT EO.ID into EST_OBJ_ID_GLOBAL 
    FROM T_ESTIMATIONOBJECT EO
    WHERE EO.INVESTIGATIONTASK_ID = INVEST_TASK_ID_GLOBAL;
  
  SELECT VC.ID into VAL_CARRIER_ID_GLOBAL
    FROM T_VALIDATIONCARRIER VC
    WHERE VC.IA_ESTIMATIONOBJECT_ID = EST_OBJ_ID_GLOBAL;
  
  ....many DELETE statements...
  
  END deleteFromStudyCase;
  </code></pre>
  
  <p>When I try to use it like this:</p>
  
  <pre><code>BEGIN
    DELETEFROMSTUDYCASE(30111);
  END;
  </code></pre>
  
  <p>At runtime it fails with this error:</p>
  
  <pre><code>Error report -
  ORA-01422: exact fetch returns more than requested number of rows
  ORA-06512: at "DELETEFROMSTUDYCASE", line 9
  ORA-06512: at line 2
  01422. 00000 -  "exact fetch returns more than requested number of rows"
  *Cause:    The number specified in exact fetch is less than the rows returned.
  *Action:   Rewrite the query or change number of rows requested
  </code></pre>
  
  <p>Meaning that one of the selects is returning more than just one value as expected. I tried so to run the select statements separately to see which one was the problem but:</p>
  
  <pre><code>SELECT IT.ID
    FROM T_INVESTIGATIONTASK IT
    WHERE IT.STUDYCASE_ID = 30111;
  </code></pre>
  
  <p>is returning only 10053.</p>
  
  <pre><code>SELECT EO.ID
    FROM T_ESTIMATIONOBJECT EO
    WHERE EO.INVESTIGATIONTASK_ID = 10053;
  </code></pre>
  
  <p>is returning only 933.</p>
  
  <pre><code>SELECT VC.ID
    FROM T_VALIDATIONCARRIER VC
    WHERE VC.IA_ESTIMATIONOBJECT_ID = 933;
  </code></pre>
  
  <p>is returning only 12.<br></p>
  
  <p>Since this part of my database has a tree structure I have also created the following procedure:</p>
  
  <pre><code>CREATE OR REPLACE PROCEDURE deleteFromInvestigationTask(invest_task_id IN NUMBER)
  IS
    VAL_CARRIER_ID_GLOBAL NUMBER(19,0);
    EST_OBJ_ID_GLOBAL NUMBER(19,0);
  BEGIN
  
  -- Fill the variables
  SELECT EO.ID into EST_OBJ_ID_GLOBAL 
    FROM T_ESTIMATIONOBJECT EO
    WHERE EO.INVESTIGATIONTASK_ID = invest_task_id;
  
  SELECT VC.ID into VAL_CARRIER_ID_GLOBAL 
    FROM T_VALIDATIONCARRIER VC
    WHERE VC.IA_ESTIMATIONOBJECT_ID = EST_OBJ_ID_GLOBAL;
  
  ...many DELETE statements...
  </code></pre>
  
  <p>And this one works correctly.<br>
  So the other one should work, why do I continue to get that error? What else could it be?</p>