You are on page 1of 5

1)crete another entity with key filed

2)copy and paste the property from dependent entity(table)

3)create Association like below screen shot

4)click next button---popup wil come--give Primary key name in the 4 th column.
/sap/opu/odata/sap/Z_FIORI_ACUSCR_PMD_SRV/AcuityDiscargePatientListSet?
$filter=AsDate eq datetime'2017-06-30T00:00:00' and TreatOu eq '1T17N' and Shift
eq'MORNING'

URL:

/sap/opu/odata/sap/Z_FIORI_ACUSCR_PMD_SRV/AcuityNurseAttendanceSet

Payload Update Create:


<?xml version="1.0" encoding="utf-8"?>
<entry xml:base="http://DEVNWNGD.ril.com:8000/sap/opu/odata/sap/Z_FIORI_ACU
SCR_PMD_SRV/" xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://
schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://
schemas.microsoft.com/ado/2007/08/dataservices">
 <id>http://DEVNWNGD.ril.com:8000/sap/opu/odata/sap/Z_FIORI_ACUSCR_PMD_SRV/
AcuityNurseAttendanceSet(Institution='RFH1',OrganizationalUnit='1T06N',Date
RecordCreated=datetime'2017-06-30T00%3A00%3A00',Shift='MORNING')</id>
 <title type="text">AcuityNurseAttendanceSet(Institution='RFH1',Organizatio
nalUnit='1T06N',DateRecordCreated=datetime'2017-06-
30T00%3A00%3A00',Shift='MORNING')</title>
 <updated>2017-07-11T05:02:40Z</updated>
 <category term="Z_FIORI_ACUSCR_PMD_SRV.AcuityNurseAttendance" scheme="http
://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
 <link href="AcuityNurseAttendanceSet(Institution='RFH1',OrganizationalUnit
='1T06N',DateRecordCreated=datetime'2017-06-
30T00%3A00%3A00',Shift='MORNING')" rel="self" title="AcuityNurseAttendance"
/>
 <content type="application/xml">
  <m:properties>
   <d:Institution>RFH1</d:Institution>
   <d:OrganizationalUnit>1T06N</d:OrganizationalUnit>
   <d:DateRecordCreated>2017-06-30T00:00:00</d:DateRecordCreated>
   <d:TimeRecordCreated>PT11H00M00S</d:TimeRecordCreated>
   <d:DateLastChange>2017-07-04T00:00:00</d:DateLastChange>
   <d:TimeLastChange>PT14H24M35S</d:TimeLastChange>
   <d:Shift>MORNING</d:Shift>
   <d:NursePresent>222</d:NursePresent>
   <d:NurseAbsent>333</d:NurseAbsent>
   <d:PlannedLeave>444</d:PlannedLeave>
  </m:properties>
 </content>
</entry>
5)click next and finish.
Create Deep entity:

URL:take HDR entity

/sap/opu/odata/sap/Z_PATIENT_SRV/Patient_updateHdrSet

json payload:in gateway click + symbol and give json by removing XML(application/atom+xml)
(application/json)

"Patid" : "4",

"NAVFROMPATIENTHDRTOTABLE":

"Patid" : "4",

"Name" : "VIJAY REDDY FFF",

"Dob" : "2017-06-30T00:00:00",

"Age" : "",

"Address" : "",

"Mobile" : "",

"Gender" : "M",

"Education" : ""

You might also like