title: Split variable and then execute query in Oracle
body: <p>I have a <code>IN</code> parameter for <code>P_R4GSTATE</code> where I am getting values for the procedure as <code>&quot;Rajasthan,Maharashtra,Haryana&quot;</code></p>
  <p>And the procedure is below:</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>PROCEDURE  GET_VENDOR_INFO
  
  (
      PVENDOR_NAME IN NVARCHAR2,
      P_R4GSTATE IN NVARCHAR2,
      P_OUTVENDOR OUT SYS_REFCURSOR
  )
  
  AS
  
  BEGIN 
  
  OPEN P_OUTVENDOR FOR
  SELECT  * FROM IPCOLO_IPFEE_CALC_MST WHERE CIRCLE=P_R4GSTATE;
  
  END IF;
  
  END GET_VENDOR_INFO;</code></pre>
  </div>
  </div>
  </p>
  <p>The issue is that data might be their in any one of those State in the table, how to execute and check for that.</p>