title: Inserting parameters into Oracle database through asp.net
body: <p>I am developing an ASP.net application with Oracle database. When I try to insert data into table REGISTER, it throws an exception as below</p>
  
  <pre><code>ORA-06550: line 1, column 7:
  PLS-00306: wrong number or types of arguments in call to 'INSERTREGISTER'
  ORA-06550: line 1, column 7:
  PL/SQL: Statement ignored
  </code></pre>
  
  <p>table <strong>REGISTER</strong> has USERNAME, PASSWORD, EMAIL as columns</p>
  
  <p>Store procedure INSERTREGISTER is as following</p>
  
  <pre><code>create or replace
  PROCEDURE INSERTREGISTER IS
  
  u1 varchar2(20);
  p1 varchar2(20);
  e1 varchar2(20);
  
  BEGIN
  
  INSERT INTO REGISTER (USERNAME, PASSWORD, EMAIL) VALUES (u1, p1, e1);
  
  END INSERTREGISTER;
  </code></pre>
  
  <p><strong>my c# code is:</strong></p>
  
  <pre><code>public int Insert(string u1, string p1, string e1)
  
      {
          try
          {
              OracleCommand cmd = new OracleCommand("INSERTREGISTER", conn);
              cmd.CommandType = CommandType.StoredProcedure;
  
          cmd.Parameters.Add(new OracleParameter("u1", OracleType.VarChar)).Value = u1;
          cmd.Parameters.Add(new OracleParameter("p1", OracleType.VarChar)).Value = p1;
          cmd.Parameters.Add(new OracleParameter("e1", OracleType.VarChar)).Value = e1;
  
              conn.Open();
              cmd.ExecuteNonQuery();
  
              return cmd.ExecuteNonQuery();
  
          }
  </code></pre>
  
  <p>Kindly help me</p>
  
  <p>regards,
  Arjun</p>