database - when i running the procedure i got the error like "cannot insert NULL into ("BPMTEAM"."T_EMPLOYEE"."E_ID")" how to resolve -


i want create on procedure when run procedure got below error please guys how resolve.

error:

ora-01400: cannot insert null ("bpmteam"."t_employee"."e_id") ora-06512: @ "bpmteam.persist_employee_proc", line 5 ora-06512: @ line 7

procedure:

create or replace procedure persist_employee_proc (emp_xml xmltype)   begin    insert t_employee (e_id, firstname, lastname, phone)  values  (  extractvalue(emp_xml, '/variable/id'),  extractvalue(emp_xml, '/variable/firstname'),  extractvalue(emp_xml, '/variable/lastname'),  extractvalue(emp_xml, '/variable/phone')  );    insert aaddress (a_id, addressline1, addressline2, city, state, zip, country)  values  (  extractvalue(emp_xml, '/variable/id'),  extractvalue(emp_xml, '/variable/address/addressline1'),  extractvalue(emp_xml, '/variable/address/addressline2'),  extractvalue(emp_xml, '/variable/address/city'),  extractvalue(emp_xml, '/variable/address/state'),  extractvalue(emp_xml, '/variable/address/zip'),  extractvalue(emp_xml, '/variable/address/country')  );  end;


Comments

Popular posts from this blog

asynchronous - C# WinSCP .NET assembly: How to upload multiple files asynchronously -

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -