Skip to content

Usages for fhir_patch_resource functions ?  #158

@sh0umik

Description

@sh0umik

I am using the update functions , It works well but it replaces the old resources doesn’t not update the fields with new value . I am looking for patch update like just updating names or address in the entire resource with the old value ..

Right now I have a whole patient resource with all the data if i try to patch update like this

SELECT fhir_patch_resource('{"resource": {"resourceType": "Patient", "id": "35", "name": [{"given": ["John"], "family": ["Smith"]}]}}'); 

Then I get this error ..

ERROR: TypeError: Cannot read property 'length' of undefined DETAIL: plv8_init() LINE 6234: var results = new Array(patches.length), p = 0, plen = patches.length, patch, key; ********** Error **********

Is there any way to do a PATCH update in fhirbase . If not then looking forward for this feature . It would make the CRUD function complete .

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions